Difference in risk between prototype and Omicon vaccines

Summary: Between Pfz Prototype, Pfz Omicron, Mdn P, and Mdn O,

Risk is similar between Pfizer and Moderna in the prototype arms. Moderna P and O have similar risks, but Pfizer O has lower risk than P.

coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ company, subset(dat.ocp,naive==1 & Trt==0))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     company, data = subset(dat.ocp, naive == 1 & Trt == 0))
## 
##              coef exp(coef) se(coef)     z     p
## companyPfz 0.4122    1.5101   0.3472 1.187 0.235
## 
## Likelihood ratio test=1.35  on 1 df, p=0.2454
## n= 105, number of events= 36
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + company + Day15pseudoneutid50_BA.4.BA.5 + FOIstandardized, subset(dat.ocp,naive==1 & Trt==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + company + Day15pseudoneutid50_BA.4.BA.5 + 
##         FOIstandardized, data = subset(dat.ocp, naive == 1 & 
##     Trt == 1))
## 
##                                  coef exp(coef) se(coef)      z        p
## standardized_risk_score        0.4680    1.5969   0.1666  2.810 0.004958
## companyPfz                    -0.9440    0.3891   0.3578 -2.638 0.008329
## Day15pseudoneutid50_BA.4.BA.5 -0.7299    0.4819   0.2006 -3.639 0.000273
## FOIstandardized               -0.1906    0.8264   0.2324 -0.820 0.412125
## 
## Likelihood ratio test=27.65  on 4 df, p=1.469e-05
## n= 213, number of events= 57
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ Trt, subset(dat.ocp,naive==1 & company=="Pfz"))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     Trt, data = subset(dat.ocp, naive == 1 & company == "Pfz"))
## 
##       coef exp(coef) se(coef)      z       p
## Trt -1.238     0.290    0.422 -2.933 0.00336
## 
## Likelihood ratio test=8.54  on 1 df, p=0.003482
## n= 98, number of events= 23
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ Trt, subset(dat.ocp,naive==1 & company=="Mdn"))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     Trt, data = subset(dat.ocp, naive == 1 & company == "Mdn"))
## 
##         coef exp(coef) se(coef)      z    p
## Trt -0.02566   0.97466  0.25475 -0.101 0.92
## 
## Likelihood ratio test=0.01  on 1 df, p=0.9199
## n= 220, number of events= 70
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ Trt * company, subset(dat.ocp, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     Trt * company, data = subset(dat.ocp, naive == 1))
## 
##                   coef exp(coef) se(coef)      z      p
## Trt            -0.0218    0.9784   0.2547 -0.086 0.9318
## companyPfz      0.4226    1.5259   0.3471  1.218 0.2234
## Trt:companyPfz -1.2309    0.2920   0.4917 -2.503 0.0123
## 
## Likelihood ratio test=10.39  on 3 df, p=0.01553
## n= 318, number of events= 93
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ I(1-Trt) * company, subset(dat.ocp, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     I(1 - Trt) * company, data = subset(dat.ocp, naive == 1))
## 
##                          coef exp(coef) se(coef)      z      p
## I(1 - Trt)             0.0218    1.0220   0.2547  0.086 0.9318
## companyPfz            -0.8083    0.4456   0.3483 -2.320 0.0203
## I(1 - Trt):companyPfz  1.2309    3.4242   0.4917  2.503 0.0123
## 
## Likelihood ratio test=10.39  on 3 df, p=0.01553
## n= 318, number of events= 93

Pfizer

OC v P is significant among the naive but not among the non-naive.

coxph(update(f, ~. + naive + Trt), dat.ocp.pfizer)
## Call:
## coxph(formula = update(f, ~. + naive + Trt), data = dat.ocp.pfizer)
## 
##                            coef exp(coef) se(coef)      z       p
## FOIstandardized         -0.1126    0.8935   0.2984 -0.377 0.70591
## standardized_risk_score  0.2795    1.3224   0.2878  0.971 0.33154
## naive                    0.8310    2.2955   0.4551  1.826 0.06787
## Trt                     -1.1399    0.3199   0.3749 -3.040 0.00236
## 
## Likelihood ratio test=12.14  on 4 df, p=0.01631
## n= 151, number of events= 30
coxph(update(f, ~. + Trt), subset(dat.ocp.pfizer, naive==0))
## Call:
## coxph(formula = update(f, ~. + Trt), data = subset(dat.ocp.pfizer, 
##     naive == 0))
## 
##                             coef exp(coef) se(coef)      z     p
## FOIstandardized          0.59531   1.81359  0.61480  0.968 0.333
## standardized_risk_score  0.04664   1.04775  0.52826  0.088 0.930
## Trt                     -0.52997   0.58862  0.77255 -0.686 0.493
## 
## Likelihood ratio test=1.38  on 3 df, p=0.7098
## n= 53, number of events= 7
coxph(update(f, ~. + Trt), subset(dat.ocp.pfizer, naive==1))
## Call:
## coxph(formula = update(f, ~. + Trt), data = subset(dat.ocp.pfizer, 
##     naive == 1))
## 
##                            coef exp(coef) se(coef)      z      p
## FOIstandardized         -0.3243    0.7231   0.3318 -0.977 0.3285
## standardized_risk_score  0.4130    1.5113   0.3592  1.150 0.2503
## Trt                     -1.3346    0.2633   0.4359 -3.062 0.0022
## 
## Likelihood ratio test=10.59  on 3 df, p=0.01415
## n= 98, number of events= 23
coxph(update(f, ~. + naive + Trt), dat.ocp.moderna)
## Call:
## coxph(formula = update(f, ~. + naive + Trt), data = dat.ocp.moderna)
## 
##                            coef exp(coef) se(coef)      z       p
## FOIstandardized         -0.1298    0.8782   0.1923 -0.675 0.49956
## standardized_risk_score  0.2056    1.2283   0.1441  1.427 0.15360
## naive                    1.0871    2.9657   0.3741  2.906 0.00367
## Trt                     -0.1180    0.8887   0.2388 -0.494 0.62124
## 
## Likelihood ratio test=13.62  on 4 df, p=0.008612
## n= 284, number of events= 78
coxph(update(f, ~. + Trt), subset(dat.ocp.moderna, naive==0))
## Call:
## coxph(formula = update(f, ~. + Trt), data = subset(dat.ocp.moderna, 
##     naive == 0))
## 
##                            coef exp(coef) se(coef)      z      p
## FOIstandardized         -0.4871    0.6144   0.5445 -0.895 0.3710
## standardized_risk_score -0.4855    0.6154   0.2100 -2.312 0.0208
## Trt                     -0.5147    0.5977   0.7306 -0.705 0.4811
## 
## Likelihood ratio test=6.87  on 3 df, p=0.07628
## n= 64, number of events= 8
coxph(update(f, ~. + Trt), subset(dat.ocp.moderna, naive==1))
## Call:
## coxph(formula = update(f, ~. + Trt), data = subset(dat.ocp.moderna, 
##     naive == 1))
## 
##                             coef exp(coef) se(coef)      z      p
## FOIstandardized         -0.03082   0.96965  0.20833 -0.148 0.8824
## standardized_risk_score  0.45535   1.57672  0.16296  2.794 0.0052
## Trt                     -0.07904   0.92400  0.25598 -0.309 0.7575
## 
## Likelihood ratio test=8.48  on 3 df, p=0.03705
## n= 220, number of events= 70
coxph(update(f, ~. + Trt), subset(dat.ocp.moderna, naive==1))
## Call:
## coxph(formula = update(f, ~. + Trt), data = subset(dat.ocp.moderna, 
##     naive == 1))
## 
##                             coef exp(coef) se(coef)      z      p
## FOIstandardized         -0.03082   0.96965  0.20833 -0.148 0.8824
## standardized_risk_score  0.45535   1.57672  0.16296  2.794 0.0052
## Trt                     -0.07904   0.92400  0.25598 -0.309 0.7575
## 
## Likelihood ratio test=8.48  on 3 df, p=0.03705
## n= 220, number of events= 70
coxph(update(f, ~. + Trt), subset(dat.ocp.pfizer, naive==1))
## Call:
## coxph(formula = update(f, ~. + Trt), data = subset(dat.ocp.pfizer, 
##     naive == 1))
## 
##                            coef exp(coef) se(coef)      z      p
## FOIstandardized         -0.3243    0.7231   0.3318 -0.977 0.3285
## standardized_risk_score  0.4130    1.5113   0.3592  1.150 0.2503
## Trt                     -1.3346    0.2633   0.4359 -3.062 0.0022
## 
## Likelihood ratio test=10.59  on 3 df, p=0.01415
## n= 98, number of events= 23
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ I(1-Trt)*scale(standardized_risk_score), subset(dat.ocp.moderna, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     I(1 - Trt) * scale(standardized_risk_score), data = subset(dat.ocp.moderna, 
##     naive == 1))
## 
##                                              coef exp(coef) se(coef)      z
## I(1 - Trt)                                 0.1259    1.1341   0.2626  0.479
## scale(standardized_risk_score)             0.4569    1.5792   0.1567  2.917
## I(1 - Trt):scale(standardized_risk_score) -0.3079    0.7350   0.2860 -1.077
##                                                 p
## I(1 - Trt)                                0.63173
## scale(standardized_risk_score)            0.00354
## I(1 - Trt):scale(standardized_risk_score) 0.28163
## 
## Likelihood ratio test=9.58  on 3 df, p=0.02251
## n= 220, number of events= 70
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ I(1-Trt)*scale(standardized_risk_score), subset(dat.ocp.pfizer, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     I(1 - Trt) * scale(standardized_risk_score), data = subset(dat.ocp.pfizer, 
##     naive == 1))
## 
##                                                coef exp(coef)  se(coef)      z
## I(1 - Trt)                                 1.334775  3.799141  0.439440  3.037
## scale(standardized_risk_score)             0.252246  1.286913  0.302894  0.833
## I(1 - Trt):scale(standardized_risk_score) -0.003043  0.996962  0.513319 -0.006
##                                                 p
## I(1 - Trt)                                0.00239
## scale(standardized_risk_score)            0.40496
## I(1 - Trt):scale(standardized_risk_score) 0.99527
## 
## Likelihood ratio test=9.64  on 3 df, p=0.02186
## n= 98, number of events= 23

D15 marker

coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ I(1-Trt)*scale(standardized_risk_score) + I(1-Trt)*scale(Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp.moderna, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     I(1 - Trt) * scale(standardized_risk_score) + I(1 - Trt) * 
##         scale(Day15pseudoneutid50_BA.4.BA.5), data = subset(dat.ocp.moderna, 
##     naive == 1))
## 
##                                                    coef exp(coef) se(coef)
## I(1 - Trt)                                       0.1114    1.1178   0.2661
## scale(standardized_risk_score)                   0.4149    1.5142   0.1504
## scale(Day15pseudoneutid50_BA.4.BA.5)            -0.4160    0.6597   0.1256
## I(1 - Trt):scale(standardized_risk_score)       -0.2653    0.7670   0.2835
## I(1 - Trt):scale(Day15pseudoneutid50_BA.4.BA.5)  0.4191    1.5206   0.2328
##                                                      z        p
## I(1 - Trt)                                       0.419 0.675561
## scale(standardized_risk_score)                   2.759 0.005804
## scale(Day15pseudoneutid50_BA.4.BA.5)            -3.311 0.000929
## I(1 - Trt):scale(standardized_risk_score)       -0.936 0.349342
## I(1 - Trt):scale(Day15pseudoneutid50_BA.4.BA.5)  1.801 0.071746
## 
## Likelihood ratio test=19.05  on 5 df, p=0.001884
## n= 220, number of events= 70
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ I(1-Trt)*scale(standardized_risk_score) + I(1-Trt)*scale(Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp.pfizer, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     I(1 - Trt) * scale(standardized_risk_score) + I(1 - Trt) * 
##         scale(Day15pseudoneutid50_BA.4.BA.5), data = subset(dat.ocp.pfizer, 
##     naive == 1))
## 
##                                                     coef exp(coef) se(coef)
## I(1 - Trt)                                       1.22319   3.39801  0.47177
## scale(standardized_risk_score)                   0.25727   1.29339  0.28060
## scale(Day15pseudoneutid50_BA.4.BA.5)            -0.39649   0.67268  0.30594
## I(1 - Trt):scale(standardized_risk_score)       -0.07131   0.93117  0.51280
## I(1 - Trt):scale(Day15pseudoneutid50_BA.4.BA.5)  0.08472   1.08841  0.48874
##                                                      z       p
## I(1 - Trt)                                       2.593 0.00952
## scale(standardized_risk_score)                   0.917 0.35923
## scale(Day15pseudoneutid50_BA.4.BA.5)            -1.296 0.19498
## I(1 - Trt):scale(standardized_risk_score)       -0.139 0.88940
## I(1 - Trt):scale(Day15pseudoneutid50_BA.4.BA.5)  0.173 0.86239
## 
## Likelihood ratio test=11.86  on 5 df, p=0.03673
## n= 98, number of events= 23
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ Trt*scale(standardized_risk_score) + Trt*scale(Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp.moderna, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     Trt * scale(standardized_risk_score) + Trt * scale(Day15pseudoneutid50_BA.4.BA.5), 
##     data = subset(dat.ocp.moderna, naive == 1))
## 
##                                               coef exp(coef)  se(coef)      z
## Trt                                      -0.111365  0.894612  0.266089 -0.419
## scale(standardized_risk_score)            0.149640  1.161417  0.240360  0.623
## scale(Day15pseudoneutid50_BA.4.BA.5)      0.003167  1.003172  0.195995  0.016
## Trt:scale(standardized_risk_score)        0.265277  1.303791  0.283455  0.936
## Trt:scale(Day15pseudoneutid50_BA.4.BA.5) -0.419130  0.657619  0.232756 -1.801
##                                               p
## Trt                                      0.6756
## scale(standardized_risk_score)           0.5336
## scale(Day15pseudoneutid50_BA.4.BA.5)     0.9871
## Trt:scale(standardized_risk_score)       0.3493
## Trt:scale(Day15pseudoneutid50_BA.4.BA.5) 0.0717
## 
## Likelihood ratio test=19.05  on 5 df, p=0.001884
## n= 220, number of events= 70
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ Trt*scale(standardized_risk_score) + Trt*scale(Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp.pfizer, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     Trt * scale(standardized_risk_score) + Trt * scale(Day15pseudoneutid50_BA.4.BA.5), 
##     data = subset(dat.ocp.pfizer, naive == 1))
## 
##                                              coef exp(coef) se(coef)      z
## Trt                                      -1.22319   0.29429  0.47177 -2.593
## scale(standardized_risk_score)            0.18595   1.20437  0.42922  0.433
## scale(Day15pseudoneutid50_BA.4.BA.5)     -0.31177   0.73215  0.38065 -0.819
## Trt:scale(standardized_risk_score)        0.07131   1.07392  0.51280  0.139
## Trt:scale(Day15pseudoneutid50_BA.4.BA.5) -0.08472   0.91877  0.48874 -0.173
##                                                p
## Trt                                      0.00952
## scale(standardized_risk_score)           0.66484
## scale(Day15pseudoneutid50_BA.4.BA.5)     0.41276
## Trt:scale(standardized_risk_score)       0.88940
## Trt:scale(Day15pseudoneutid50_BA.4.BA.5) 0.86239
## 
## Likelihood ratio test=11.86  on 5 df, p=0.03673
## n= 98, number of events= 23
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ Trt*scale(standardized_risk_score) + scale(Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp.moderna, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     Trt * scale(standardized_risk_score) + scale(Day15pseudoneutid50_BA.4.BA.5), 
##     data = subset(dat.ocp.moderna, naive == 1))
## 
##                                          coef exp(coef) se(coef)      z       p
## Trt                                   0.01104   1.01111  0.26824  0.041 0.96716
## scale(standardized_risk_score)        0.19188   1.21152  0.23255  0.825 0.40932
## scale(Day15pseudoneutid50_BA.4.BA.5) -0.27822   0.75713  0.10780 -2.581 0.00986
## Trt:scale(standardized_risk_score)    0.23881   1.26974  0.27919  0.855 0.39234
## 
## Likelihood ratio test=15.7  on 4 df, p=0.003451
## n= 220, number of events= 70
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ Trt+scale(standardized_risk_score) + scale(Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp.pfizer, naive==1))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     Trt + scale(standardized_risk_score) + scale(Day15pseudoneutid50_BA.4.BA.5), 
##     data = subset(dat.ocp.pfizer, naive == 1))
## 
##                                         coef exp(coef) se(coef)      z       p
## Trt                                  -1.1912    0.3039   0.4390 -2.713 0.00666
## scale(standardized_risk_score)        0.2285    1.2567   0.2312  0.988 0.32313
## scale(Day15pseudoneutid50_BA.4.BA.5) -0.3558    0.7006   0.2317 -1.536 0.12463
## 
## Likelihood ratio test=11.81  on 3 df, p=0.008078
## n= 98, number of events= 23

BA4BA5-specific ID50 is significant correlate but not ancestral ID50.

coxph(update(f, ~. + Trt * Bpseudoneutid50_BA.4.BA.5), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt * Bpseudoneutid50_BA.4.BA.5), 
##     data = dat.1)
## 
##                                   coef exp(coef) se(coef)      z     p
## FOIstandardized               -0.37008   0.69068  0.32778 -1.129 0.259
## standardized_risk_score        0.46192   1.58712  0.35856  1.288 0.198
## Trt                           -1.45196   0.23411  1.39782 -1.039 0.299
## Bpseudoneutid50_BA.4.BA.5     -0.76476   0.46545  0.51612 -1.482 0.138
## Trt:Bpseudoneutid50_BA.4.BA.5  0.02565   1.02598  0.75166  0.034 0.973
## 
## Likelihood ratio test=14.86  on 5 df, p=0.011
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5), 
##     data = dat.1)
## 
##                              coef exp(coef) se(coef)      z       p
## FOIstandardized           -0.3707    0.6903   0.3275 -1.132 0.25778
## standardized_risk_score    0.4619    1.5871   0.3584  1.289 0.19754
## Trt                       -1.4067    0.2449   0.4402 -3.196 0.00139
## Bpseudoneutid50_BA.4.BA.5 -0.7528    0.4711   0.3771 -1.996 0.04593
## 
## Likelihood ratio test=14.85  on 4 df, p=0.005012
## n= 98, number of events= 23
coxph(update(f, ~. + Trt * Day15pseudoneutid50_BA.4.BA.5), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt * Day15pseudoneutid50_BA.4.BA.5), 
##     data = dat.1)
## 
##                                      coef exp(coef) se(coef)      z     p
## FOIstandardized                   -0.3928    0.6751   0.3376 -1.163 0.245
## standardized_risk_score            0.4077    1.5033   0.3387  1.204 0.229
## Trt                               -0.5003    0.6063   2.3862 -0.210 0.834
## Day15pseudoneutid50_BA.4.BA.5     -0.5345    0.5860   0.6290 -0.850 0.395
## Trt:Day15pseudoneutid50_BA.4.BA.5 -0.2392    0.7873   0.8374 -0.286 0.775
## 
## Likelihood ratio test=13.19  on 5 df, p=0.0217
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Day15pseudoneutid50_BA.4.BA.5), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Day15pseudoneutid50_BA.4.BA.5), 
##     data = dat.1)
## 
##                                  coef exp(coef) se(coef)      z       p
## FOIstandardized               -0.3846    0.6807   0.3365 -1.143 0.25298
## standardized_risk_score        0.3880    1.4741   0.3346  1.160 0.24613
## Trt                           -1.1710    0.3101   0.4380 -2.673 0.00751
## Day15pseudoneutid50_BA.4.BA.5 -0.6690    0.5122   0.4026 -1.661 0.09662
## 
## Likelihood ratio test=13.1  on 4 df, p=0.01078
## n= 98, number of events= 23
coxph(update(f, ~. + Trt * Bpseudoneutid50_D614G), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt * Bpseudoneutid50_D614G), 
##     data = dat.1)
## 
##                              coef exp(coef) se(coef)      z     p
## FOIstandardized           -0.3129    0.7313   0.3325 -0.941 0.347
## standardized_risk_score    0.3846    1.4690   0.3593  1.070 0.284
## Trt                       -2.5917    0.0749   3.0261 -0.856 0.392
## Bpseudoneutid50_D614G     -0.7526    0.4711   0.6990 -1.077 0.282
## Trt:Bpseudoneutid50_D614G  0.3747    1.4545   0.9066  0.413 0.679
## 
## Likelihood ratio test=12.25  on 5 df, p=0.03156
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G), 
##     data = dat.1)
## 
##                            coef exp(coef) se(coef)      z       p
## FOIstandardized         -0.3433    0.7094   0.3265 -1.051 0.29307
## standardized_risk_score  0.4042    1.4981   0.3542  1.141 0.25378
## Trt                     -1.3536    0.2583   0.4357 -3.106 0.00189
## Bpseudoneutid50_D614G   -0.5220    0.5934   0.4159 -1.255 0.20949
## 
## Likelihood ratio test=12.07  on 4 df, p=0.01682
## n= 98, number of events= 23
coxph(update(f, ~. + Trt * Day15pseudoneutid50_D614G), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt * Day15pseudoneutid50_D614G), 
##     data = dat.1)
## 
##                                   coef exp(coef) se(coef)      z     p
## FOIstandardized               -0.34880   0.70554  0.33352 -1.046 0.296
## standardized_risk_score        0.37937   1.46136  0.33824  1.122 0.262
## Trt                            2.10109   8.17504  5.09592  0.412 0.680
## Day15pseudoneutid50_D614G      0.06733   1.06965  0.98947  0.068 0.946
## Trt:Day15pseudoneutid50_D614G -0.81890   0.44092  1.22190 -0.670 0.503
## 
## Likelihood ratio test=11.66  on 5 df, p=0.03977
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Day15pseudoneutid50_D614G), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Day15pseudoneutid50_D614G), 
##     data = dat.1)
## 
##                              coef exp(coef) se(coef)      z       p
## FOIstandardized           -0.3568    0.6999   0.3320 -1.075 0.28252
## standardized_risk_score    0.3775    1.4586   0.3485  1.083 0.27878
## Trt                       -1.3000    0.2725   0.4364 -2.979 0.00289
## Day15pseudoneutid50_D614G -0.4664    0.6273   0.5907 -0.789 0.42983
## 
## Likelihood ratio test=11.21  on 4 df, p=0.02432
## n= 98, number of events= 23

Distribution of D15 BA4BA5-specific ID50 is different between P and OC

par(mfrow=c(1,2))
myboxplot(Bpseudoneutid50_BA.4.BA.5~Trt, dat.1, test="w")
myboxplot(Day15pseudoneutid50_BA.4.BA.5~Trt, dat.1, test="w")

Additional marker models

coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G + Day15pseudoneutid50_D614G + I(Day15pseudoneutid50_D614G^2)), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G + 
##     Day15pseudoneutid50_D614G + I(Day15pseudoneutid50_D614G^2)), 
##     data = dat.1)
## 
##                                   coef exp(coef) se(coef)      z       p
## FOIstandardized                -0.3455    0.7079   0.3285 -1.052 0.29297
## standardized_risk_score         0.3851    1.4697   0.3798  1.014 0.31063
## Trt                            -1.3295    0.2646   0.4678 -2.842 0.00449
## Bpseudoneutid50_D614G          -0.4862    0.6150   0.4908 -0.991 0.32187
## Day15pseudoneutid50_D614G       0.7199    2.0541   9.1491  0.079 0.93729
## I(Day15pseudoneutid50_D614G^2) -0.0983    0.9064   1.0962 -0.090 0.92855
## 
## Likelihood ratio test=12.1  on 6 df, p=0.05974
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G * Day15pseudoneutid50_D614G), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G * 
##     Day15pseudoneutid50_D614G), data = dat.1)
## 
##                                                    coef exp(coef) se(coef)
## FOIstandardized                                 -0.3629    0.6956   0.3266
## standardized_risk_score                          0.3633    1.4380   0.3727
## Trt                                             -1.2999    0.2725   0.4475
## Bpseudoneutid50_D614G                            2.9004   18.1816   6.1345
## Day15pseudoneutid50_D614G                        2.4931   12.0987   4.7804
## Bpseudoneutid50_D614G:Day15pseudoneutid50_D614G -0.8016    0.4486   1.4502
##                                                      z       p
## FOIstandardized                                 -1.111 0.26650
## standardized_risk_score                          0.975 0.32977
## Trt                                             -2.905 0.00368
## Bpseudoneutid50_D614G                            0.473 0.63635
## Day15pseudoneutid50_D614G                        0.522 0.60200
## Bpseudoneutid50_D614G:Day15pseudoneutid50_D614G -0.553 0.58043
## 
## Likelihood ratio test=12.44  on 6 df, p=0.05286
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G + Day15pseudoneutid50_D614G), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G + 
##     Day15pseudoneutid50_D614G), data = dat.1)
## 
##                               coef exp(coef) se(coef)      z       p
## FOIstandardized           -0.34752   0.70644  0.32782 -1.060 0.28910
## standardized_risk_score    0.39723   1.48770  0.35421  1.121 0.26210
## Trt                       -1.34393   0.26082  0.44034 -3.052 0.00227
## Bpseudoneutid50_D614G     -0.48573   0.61525  0.49278 -0.986 0.32428
## Day15pseudoneutid50_D614G -0.09788   0.90675  0.68958 -0.142 0.88712
## 
## Likelihood ratio test=12.09  on 5 df, p=0.03353
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G), 
##     data = dat.1)
## 
##                            coef exp(coef) se(coef)      z       p
## FOIstandardized         -0.3433    0.7094   0.3265 -1.051 0.29307
## standardized_risk_score  0.4042    1.4981   0.3542  1.141 0.25378
## Trt                     -1.3536    0.2583   0.4357 -3.106 0.00189
## Bpseudoneutid50_D614G   -0.5220    0.5934   0.4159 -1.255 0.20949
## 
## Likelihood ratio test=12.07  on 4 df, p=0.01682
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Day15pseudoneutid50_D614G), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Day15pseudoneutid50_D614G), 
##     data = dat.1)
## 
##                              coef exp(coef) se(coef)      z       p
## FOIstandardized           -0.3568    0.6999   0.3320 -1.075 0.28252
## standardized_risk_score    0.3775    1.4586   0.3485  1.083 0.27878
## Trt                       -1.3000    0.2725   0.4364 -2.979 0.00289
## Day15pseudoneutid50_D614G -0.4664    0.6273   0.5907 -0.789 0.42983
## 
## Likelihood ratio test=11.21  on 4 df, p=0.02432
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 + Day15pseudoneutid50_BA.4.BA.5 + I(Day15pseudoneutid50_BA.4.BA.5^2)), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 + 
##     Day15pseudoneutid50_BA.4.BA.5 + I(Day15pseudoneutid50_BA.4.BA.5^2)), 
##     data = dat.1)
## 
##                                        coef exp(coef) se(coef)      z       p
## FOIstandardized                    -0.39082   0.67650  0.33397 -1.170 0.24192
## standardized_risk_score             0.44598   1.56201  0.35217  1.266 0.20538
## Trt                                -1.32656   0.26539  0.48196 -2.752 0.00592
## Bpseudoneutid50_BA.4.BA.5          -0.63623   0.52928  0.44876 -1.418 0.15626
## Day15pseudoneutid50_BA.4.BA.5      -0.46895   0.62566  2.24326 -0.209 0.83441
## I(Day15pseudoneutid50_BA.4.BA.5^2)  0.03931   1.04009  0.41458  0.095 0.92446
## 
## Likelihood ratio test=15.12  on 6 df, p=0.01931
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 * Day15pseudoneutid50_BA.4.BA.5), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 * 
##     Day15pseudoneutid50_BA.4.BA.5), data = dat.1)
## 
##                                                            coef exp(coef)
## FOIstandardized                                         -0.3963    0.6728
## standardized_risk_score                                  0.4624    1.5879
## Trt                                                     -1.3413    0.2615
## Bpseudoneutid50_BA.4.BA.5                               -1.5970    0.2025
## Day15pseudoneutid50_BA.4.BA.5                           -0.7192    0.4871
## Bpseudoneutid50_BA.4.BA.5:Day15pseudoneutid50_BA.4.BA.5  0.3065    1.3587
##                                                         se(coef)      z       p
## FOIstandardized                                           0.3337 -1.188 0.23499
## standardized_risk_score                                   0.3541  1.306 0.19161
## Trt                                                       0.4739 -2.830 0.00465
## Bpseudoneutid50_BA.4.BA.5                                 2.8898 -0.553 0.58053
## Day15pseudoneutid50_BA.4.BA.5                             1.4386 -0.500 0.61712
## Bpseudoneutid50_BA.4.BA.5:Day15pseudoneutid50_BA.4.BA.5   0.9028  0.340 0.73419
## 
## Likelihood ratio test=15.23  on 6 df, p=0.01856
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 + Day15pseudoneutid50_BA.4.BA.5), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 + 
##     Day15pseudoneutid50_BA.4.BA.5), data = dat.1)
## 
##                                  coef exp(coef) se(coef)      z      p
## FOIstandardized               -0.3932    0.6749   0.3327 -1.182 0.2373
## standardized_risk_score        0.4418    1.5555   0.3494  1.264 0.2061
## Trt                           -1.3153    0.2684   0.4664 -2.820 0.0048
## Bpseudoneutid50_BA.4.BA.5     -0.6318    0.5316   0.4472 -1.413 0.1577
## Day15pseudoneutid50_BA.4.BA.5 -0.2616    0.7698   0.5056 -0.517 0.6049
## 
## Likelihood ratio test=15.12  on 5 df, p=0.009877
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5), 
##     data = dat.1)
## 
##                              coef exp(coef) se(coef)      z       p
## FOIstandardized           -0.3707    0.6903   0.3275 -1.132 0.25778
## standardized_risk_score    0.4619    1.5871   0.3584  1.289 0.19754
## Trt                       -1.4067    0.2449   0.4402 -3.196 0.00139
## Bpseudoneutid50_BA.4.BA.5 -0.7528    0.4711   0.3771 -1.996 0.04593
## 
## Likelihood ratio test=14.85  on 4 df, p=0.005012
## n= 98, number of events= 23
coxph(update(f, ~. + Trt + Day15pseudoneutid50_BA.4.BA.5), dat.1)
## Call:
## coxph(formula = update(f, ~. + Trt + Day15pseudoneutid50_BA.4.BA.5), 
##     data = dat.1)
## 
##                                  coef exp(coef) se(coef)      z       p
## FOIstandardized               -0.3846    0.6807   0.3365 -1.143 0.25298
## standardized_risk_score        0.3880    1.4741   0.3346  1.160 0.24613
## Trt                           -1.1710    0.3101   0.4380 -2.673 0.00751
## Day15pseudoneutid50_BA.4.BA.5 -0.6690    0.5122   0.4026 -1.661 0.09662
## 
## Likelihood ratio test=13.1  on 4 df, p=0.01078
## n= 98, number of events= 23

Moderna

No treatment effect in either naive or non-naive.

coxph(update(f, ~. + naive + Trt), dat.ocp.moderna)
## Call:
## coxph(formula = update(f, ~. + naive + Trt), data = dat.ocp.moderna)
## 
##                            coef exp(coef) se(coef)      z       p
## FOIstandardized         -0.1298    0.8782   0.1923 -0.675 0.49956
## standardized_risk_score  0.2056    1.2283   0.1441  1.427 0.15360
## naive                    1.0871    2.9657   0.3741  2.906 0.00367
## Trt                     -0.1180    0.8887   0.2388 -0.494 0.62124
## 
## Likelihood ratio test=13.62  on 4 df, p=0.008612
## n= 284, number of events= 78
coxph(update(f, ~. + naive + Trt), subset(dat.ocp.moderna, naive==0))
## Call:
## coxph(formula = update(f, ~. + naive + Trt), data = subset(dat.ocp.moderna, 
##     naive == 0))
## 
##                            coef exp(coef) se(coef)      z      p
## FOIstandardized         -0.4871    0.6144   0.5445 -0.895 0.3710
## standardized_risk_score -0.4855    0.6154   0.2100 -2.312 0.0208
## naive                        NA        NA   0.0000     NA     NA
## Trt                     -0.5147    0.5977   0.7306 -0.705 0.4811
## 
## Likelihood ratio test=6.87  on 3 df, p=0.07628
## n= 64, number of events= 8
coxph(update(f, ~. + naive + Trt), subset(dat.ocp.moderna, naive==1))
## Call:
## coxph(formula = update(f, ~. + naive + Trt), data = subset(dat.ocp.moderna, 
##     naive == 1))
## 
##                             coef exp(coef) se(coef)      z      p
## FOIstandardized         -0.03082   0.96965  0.20833 -0.148 0.8824
## standardized_risk_score  0.45535   1.57672  0.16296  2.794 0.0052
## naive                         NA        NA  0.00000     NA     NA
## Trt                     -0.07904   0.92400  0.25598 -0.309 0.7575
## 
## Likelihood ratio test=8.48  on 3 df, p=0.03705
## n= 220, number of events= 70

Distribution of D15 BA4BA5-specific ID50 is different between P and OC

par(mfrow=c(1,2))
myboxplot(Bpseudoneutid50_BA.4.BA.5~Trt, dat.1.moderna, test="w")
myboxplot(Day15pseudoneutid50_BA.4.BA.5~Trt, dat.1.moderna, test="w")

Among naive, there is significant interaction between Trt and D1 BA4BA5 ID50

coxph(update(f, ~. + Trt * Bpseudoneutid50_BA.4.BA.5), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt * Bpseudoneutid50_BA.4.BA.5), 
##     data = dat.1.moderna)
## 
##                                   coef exp(coef) se(coef)      z       p
## FOIstandardized               -0.10876   0.89694  0.21194 -0.513 0.60782
## standardized_risk_score        0.51757   1.67794  0.17018  3.041 0.00236
## Trt                            1.43400   4.19546  0.80039  1.792 0.07319
## Bpseudoneutid50_BA.4.BA.5     -0.03369   0.96687  0.31280 -0.108 0.91422
## Trt:Bpseudoneutid50_BA.4.BA.5 -0.78765   0.45491  0.38980 -2.021 0.04332
## 
## Likelihood ratio test=22.09  on 5 df, p=0.0005028
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5), 
##     data = dat.1.moderna)
## 
##                               coef exp(coef) se(coef)      z      p
## FOIstandardized           -0.08466   0.91883  0.21020 -0.403 0.6871
## standardized_risk_score    0.52343   1.68781  0.16853  3.106 0.0019
## Trt                       -0.05426   0.94719  0.25656 -0.211 0.8325
## Bpseudoneutid50_BA.4.BA.5 -0.55763   0.57256  0.18591 -3.000 0.0027
## 
## Likelihood ratio test=18.02  on 4 df, p=0.001224
## n= 220, number of events= 70
coxph(update(f, ~. + Trt * Day15pseudoneutid50_BA.4.BA.5), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt * Day15pseudoneutid50_BA.4.BA.5), 
##     data = dat.1.moderna)
## 
##                                        coef exp(coef)  se(coef)      z       p
## FOIstandardized                   -0.063658  0.938326  0.208384 -0.305 0.76000
## standardized_risk_score            0.419372  1.521006  0.158592  2.644 0.00818
## Trt                                2.167095  8.732879  1.238928  1.749 0.08026
## Day15pseudoneutid50_BA.4.BA.5     -0.006817  0.993206  0.346598 -0.020 0.98431
## Trt:Day15pseudoneutid50_BA.4.BA.5 -0.725744  0.483964  0.409206 -1.774 0.07614
## 
## Likelihood ratio test=18.29  on 5 df, p=0.002603
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Day15pseudoneutid50_BA.4.BA.5), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Day15pseudoneutid50_BA.4.BA.5), 
##     data = dat.1.moderna)
## 
##                                   coef exp(coef) se(coef)      z       p
## FOIstandardized               -0.04024   0.96056  0.20792 -0.194 0.84655
## standardized_risk_score        0.44264   1.55682  0.15841  2.794 0.00520
## Trt                            0.05208   1.05347  0.26166  0.199 0.84222
## Day15pseudoneutid50_BA.4.BA.5 -0.49862   0.60737  0.18590 -2.682 0.00731
## 
## Likelihood ratio test=15.02  on 4 df, p=0.004658
## n= 220, number of events= 70
coxph(update(f, ~. + Trt * Bpseudoneutid50_D614G), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt * Bpseudoneutid50_D614G), 
##     data = dat.1.moderna)
## 
##                               coef exp(coef) se(coef)      z       p
## FOIstandardized           -0.01409   0.98600  0.21342 -0.066 0.94734
## standardized_risk_score    0.48600   1.62579  0.16721  2.906 0.00366
## Trt                        1.57583   4.83477  1.56471  1.007 0.31388
## Bpseudoneutid50_D614G     -0.22904   0.79530  0.40054 -0.572 0.56745
## Trt:Bpseudoneutid50_D614G -0.48992   0.61268  0.46328 -1.058 0.29028
## 
## Likelihood ratio test=17.22  on 5 df, p=0.004097
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G), 
##     data = dat.1.moderna)
## 
##                              coef exp(coef)  se(coef)      z       p
## FOIstandardized          0.005631  1.005647  0.211626  0.027 0.97877
## standardized_risk_score  0.489978  1.632280  0.166749  2.938 0.00330
## Trt                     -0.042098  0.958776  0.256407 -0.164 0.86959
## Bpseudoneutid50_D614G   -0.591856  0.553299  0.210497 -2.812 0.00493
## 
## Likelihood ratio test=16.12  on 4 df, p=0.002862
## n= 220, number of events= 70
coxph(update(f, ~. + Trt * Day15pseudoneutid50_D614G), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt * Day15pseudoneutid50_D614G), 
##     data = dat.1.moderna)
## 
##                                   coef exp(coef) se(coef)      z       p
## FOIstandardized               -0.04257   0.95833  0.21104 -0.202 0.84015
## standardized_risk_score        0.42967   1.53675  0.16333  2.631 0.00852
## Trt                            2.75942  15.79061  2.68283  1.029 0.30369
## Day15pseudoneutid50_D614G     -0.33609   0.71456  0.52728 -0.637 0.52386
## Trt:Day15pseudoneutid50_D614G -0.67350   0.50992  0.63901 -1.054 0.29190
## 
## Likelihood ratio test=16.55  on 5 df, p=0.005445
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Day15pseudoneutid50_D614G), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Day15pseudoneutid50_D614G), 
##     data = dat.1.moderna)
## 
##                               coef exp(coef) se(coef)      z       p
## FOIstandardized           -0.02905   0.97137  0.20991 -0.138 0.88992
## standardized_risk_score    0.43341   1.54250  0.16353  2.650 0.00804
## Trt                       -0.04242   0.95847  0.25644 -0.165 0.86862
## Day15pseudoneutid50_D614G -0.78976   0.45395  0.29689 -2.660 0.00781
## 
## Likelihood ratio test=15.42  on 4 df, p=0.003899
## n= 220, number of events= 70

Additional marker models

coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G + Day15pseudoneutid50_D614G + I(Day15pseudoneutid50_D614G^2)), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G + 
##     Day15pseudoneutid50_D614G + I(Day15pseudoneutid50_D614G^2)), 
##     data = dat.1.moderna)
## 
##                                      coef  exp(coef)   se(coef)      z      p
## FOIstandardized                -5.814e-03  9.942e-01  2.114e-01 -0.028 0.9781
## standardized_risk_score         4.733e-01  1.605e+00  1.694e-01  2.794 0.0052
## Trt                            -3.537e-02  9.653e-01  2.567e-01 -0.138 0.8904
## Bpseudoneutid50_D614G          -4.341e-01  6.478e-01  2.870e-01 -1.513 0.1304
## Day15pseudoneutid50_D614G       9.463e+00  1.287e+04  6.180e+00  1.531 0.1257
## I(Day15pseudoneutid50_D614G^2) -1.195e+00  3.028e-01  7.478e-01 -1.598 0.1101
## 
## Likelihood ratio test=20.2  on 6 df, p=0.00255
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G * Day15pseudoneutid50_D614G), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G * 
##     Day15pseudoneutid50_D614G), data = dat.1.moderna)
## 
##                                                     coef exp(coef) se(coef)
## FOIstandardized                                 -0.02009   0.98011  0.21239
## standardized_risk_score                          0.47970   1.61559  0.16983
## Trt                                             -0.04103   0.95980  0.25641
## Bpseudoneutid50_D614G                            3.60636  36.83171  2.59976
## Day15pseudoneutid50_D614G                        2.52712  12.51740  1.94240
## Bpseudoneutid50_D614G:Day15pseudoneutid50_D614G -0.94366   0.38920  0.61038
##                                                      z       p
## FOIstandardized                                 -0.095 0.92463
## standardized_risk_score                          2.825 0.00473
## Trt                                             -0.160 0.87285
## Bpseudoneutid50_D614G                            1.387 0.16538
## Day15pseudoneutid50_D614G                        1.301 0.19325
## Bpseudoneutid50_D614G:Day15pseudoneutid50_D614G -1.546 0.12210
## 
## Likelihood ratio test=19.83  on 6 df, p=0.002965
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G + Day15pseudoneutid50_D614G), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G + 
##     Day15pseudoneutid50_D614G), data = dat.1.moderna)
## 
##                                coef exp(coef)  se(coef)      z      p
## FOIstandardized           -0.007339  0.992688  0.211648 -0.035 0.9723
## standardized_risk_score    0.462311  1.587738  0.167240  2.764 0.0057
## Trt                       -0.031277  0.969207  0.256769 -0.122 0.9030
## Bpseudoneutid50_D614G     -0.395893  0.673078  0.293522 -1.349 0.1774
## Day15pseudoneutid50_D614G -0.406311  0.666103  0.404493 -1.004 0.3151
## 
## Likelihood ratio test=17.16  on 5 df, p=0.004213
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Bpseudoneutid50_D614G), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_D614G), 
##     data = dat.1.moderna)
## 
##                              coef exp(coef)  se(coef)      z       p
## FOIstandardized          0.005631  1.005647  0.211626  0.027 0.97877
## standardized_risk_score  0.489978  1.632280  0.166749  2.938 0.00330
## Trt                     -0.042098  0.958776  0.256407 -0.164 0.86959
## Bpseudoneutid50_D614G   -0.591856  0.553299  0.210497 -2.812 0.00493
## 
## Likelihood ratio test=16.12  on 4 df, p=0.002862
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Day15pseudoneutid50_D614G), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Day15pseudoneutid50_D614G), 
##     data = dat.1.moderna)
## 
##                               coef exp(coef) se(coef)      z       p
## FOIstandardized           -0.02905   0.97137  0.20991 -0.138 0.88992
## standardized_risk_score    0.43341   1.54250  0.16353  2.650 0.00804
## Trt                       -0.04242   0.95847  0.25644 -0.165 0.86862
## Day15pseudoneutid50_D614G -0.78976   0.45395  0.29689 -2.660 0.00781
## 
## Likelihood ratio test=15.42  on 4 df, p=0.003899
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 + Day15pseudoneutid50_BA.4.BA.5 + I(Day15pseudoneutid50_BA.4.BA.5^2)), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 + 
##     Day15pseudoneutid50_BA.4.BA.5 + I(Day15pseudoneutid50_BA.4.BA.5^2)), 
##     data = dat.1.moderna)
## 
##                                         coef exp(coef)  se(coef)      z       p
## FOIstandardized                     -0.16507   0.84784   0.21337 -0.774 0.43916
## standardized_risk_score              0.45693   1.57922   0.16953  2.695 0.00703
## Trt                                  0.09869   1.10373   0.26505  0.372 0.70963
## Bpseudoneutid50_BA.4.BA.5           -0.18224   0.83340   0.24952 -0.730 0.46517
## Day15pseudoneutid50_BA.4.BA.5        4.87481 130.94983   1.87375  2.602 0.00928
## I(Day15pseudoneutid50_BA.4.BA.5^2)  -0.97889   0.37573   0.34700 -2.821 0.00479
## 
## Likelihood ratio test=29.29  on 6 df, p=5.372e-05
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 * Day15pseudoneutid50_BA.4.BA.5), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 * 
##     Day15pseudoneutid50_BA.4.BA.5), data = dat.1.moderna)
## 
##                                                              coef exp(coef)
## FOIstandardized                                          -0.13156   0.87673
## standardized_risk_score                                   0.45336   1.57359
## Trt                                                       0.04978   1.05104
## Bpseudoneutid50_BA.4.BA.5                                 5.66331 288.10120
## Day15pseudoneutid50_BA.4.BA.5                             2.57487  13.12966
## Bpseudoneutid50_BA.4.BA.5:Day15pseudoneutid50_BA.4.BA.5  -1.87482   0.15338
##                                                          se(coef)      z
## FOIstandardized                                           0.21151 -0.622
## standardized_risk_score                                   0.16885  2.685
## Trt                                                       0.26683  0.187
## Bpseudoneutid50_BA.4.BA.5                                 1.70177  3.328
## Day15pseudoneutid50_BA.4.BA.5                             0.84488  3.048
## Bpseudoneutid50_BA.4.BA.5:Day15pseudoneutid50_BA.4.BA.5   0.53345 -3.515
##                                                                p
## FOIstandardized                                         0.533957
## standardized_risk_score                                 0.007252
## Trt                                                     0.851993
## Bpseudoneutid50_BA.4.BA.5                               0.000875
## Day15pseudoneutid50_BA.4.BA.5                           0.002307
## Bpseudoneutid50_BA.4.BA.5:Day15pseudoneutid50_BA.4.BA.5 0.000441
## 
## Likelihood ratio test=32.41  on 6 df, p=1.363e-05
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 + Day15pseudoneutid50_BA.4.BA.5), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5 + 
##     Day15pseudoneutid50_BA.4.BA.5), data = dat.1.moderna)
## 
##                                    coef exp(coef)  se(coef)      z       p
## FOIstandardized               -0.076829  0.926048  0.209936 -0.366 0.71439
## standardized_risk_score        0.501798  1.651689  0.167333  2.999 0.00271
## Trt                           -0.002618  0.997386  0.264350 -0.010 0.99210
## Bpseudoneutid50_BA.4.BA.5     -0.445376  0.640583  0.233371 -1.908 0.05633
## Day15pseudoneutid50_BA.4.BA.5 -0.201700  0.817340  0.246766 -0.817 0.41371
## 
## Likelihood ratio test=18.67  on 5 df, p=0.002214
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Bpseudoneutid50_BA.4.BA.5), 
##     data = dat.1.moderna)
## 
##                               coef exp(coef) se(coef)      z      p
## FOIstandardized           -0.08466   0.91883  0.21020 -0.403 0.6871
## standardized_risk_score    0.52343   1.68781  0.16853  3.106 0.0019
## Trt                       -0.05426   0.94719  0.25656 -0.211 0.8325
## Bpseudoneutid50_BA.4.BA.5 -0.55763   0.57256  0.18591 -3.000 0.0027
## 
## Likelihood ratio test=18.02  on 4 df, p=0.001224
## n= 220, number of events= 70
coxph(update(f, ~. + Trt + Day15pseudoneutid50_BA.4.BA.5), dat.1.moderna)
## Call:
## coxph(formula = update(f, ~. + Trt + Day15pseudoneutid50_BA.4.BA.5), 
##     data = dat.1.moderna)
## 
##                                   coef exp(coef) se(coef)      z       p
## FOIstandardized               -0.04024   0.96056  0.20792 -0.194 0.84655
## standardized_risk_score        0.44264   1.55682  0.15841  2.794 0.00520
## Trt                            0.05208   1.05347  0.26166  0.199 0.84222
## Day15pseudoneutid50_BA.4.BA.5 -0.49862   0.60737  0.18590 -2.682 0.00731
## 
## Likelihood ratio test=15.02  on 4 df, p=0.004658
## n= 220, number of events= 70
coxph(update(f, ~.  + Day15pseudoneutid50_BA.4.BA.5), subset(dat.1.moderna, Trt==1))
## Call:
## coxph(formula = update(f, ~. + Day15pseudoneutid50_BA.4.BA.5), 
##     data = subset(dat.1.moderna, Trt == 1))
## 
##                                  coef exp(coef) se(coef)      z        p
## FOIstandardized               -0.1627    0.8498   0.2699 -0.603 0.546488
## standardized_risk_score        0.4981    1.6456   0.1865  2.670 0.007581
## Day15pseudoneutid50_BA.4.BA.5 -0.7579    0.4686   0.2176 -3.484 0.000495
## 
## Likelihood ratio test=19.88  on 3 df, p=0.0001794
## n= 145, number of events= 47
coxph(update(f, ~.  + Day15pseudoneutid50_D614G), subset(dat.1.moderna, Trt==1))
## Call:
## coxph(formula = update(f, ~. + Day15pseudoneutid50_D614G), data = subset(dat.1.moderna, 
##     Trt == 1))
## 
##                              coef exp(coef) se(coef)      z       p
## FOIstandardized           -0.1406    0.8688   0.2749 -0.512 0.60893
## standardized_risk_score    0.5205    1.6829   0.1945  2.676 0.00745
## Day15pseudoneutid50_D614G -1.0358    0.3549   0.3641 -2.845 0.00444
## 
## Likelihood ratio test=17.49  on 3 df, p=0.000561
## n= 145, number of events= 47

Putting Pfizer and Moderna side by side

Omicron-specific antibodies are similar at D1, rise at D15, and more so when vaccines contain Omicron strains.

par(mfrow=c(1,2))
myboxplot(Bpseudoneutid50_BA.4.BA.5~Trt+company, subset(dat.ocp, naive==1), cex.axis=.8)
myboxplot(Day15pseudoneutid50_BA.4.BA.5~Trt+company, subset(dat.ocp, naive==1), cex.axis=.8)

Ancestral antibodies are not quite similar at D1, rise at D15, but not more so when vaccines contain Omicron strains.

par(mfrow=c(1,2))
myboxplot(Bpseudoneutid50_D614G~Trt+company, subset(dat.ocp, naive==1), cex.axis=.8)
myboxplot(Day15pseudoneutid50_D614G~Trt+company, subset(dat.ocp, naive==1), cex.axis=.8)

fits=list()
fits[["Pfz,P"]] = coxph(update(f, ~.  + Day15pseudoneutid50_D614G), subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0))
fits[["Pfz,O"]] = coxph(update(f, ~.  + Day15pseudoneutid50_D614G), subset(dat.ocp, naive==1 & company=="Pfz" & Trt==1))
fits[["Mdn,P"]] = coxph(update(f, ~.  + Day15pseudoneutid50_D614G), subset(dat.ocp, naive==1 & company=="Mdn" & Trt==0))
fits[["Mdn,O"]] = coxph(update(f, ~.  + Day15pseudoneutid50_D614G), subset(dat.ocp, naive==1 & company=="Mdn" & Trt==1))
tab = getFormattedSummary(fits, robust=F, type=5)
tab
##                           Pfz,P   Pfz,O   Mdn,P   Mdn,O    
## FOIstandardized           "-0.49" "-0.22" "0.19"  "-0.14"  
## standardized_risk_score   "0.36"  "0.36"  "0.15"  "0.52**" 
## Day15pseudoneutid50_D614G "-0.15" "-0.70" "-0.37" "-1.04**"

Are risk scores distribution different?

myboxplot(standardized_risk_score    ~Trt+company, subset(dat.ocp, naive==1), cex.axis=.8)

coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score*Trt, subset(dat.ocp, naive==1 & company=="Mdn"))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score * Trt, data = subset(dat.ocp, naive == 
##     1 & company == "Mdn"))
## 
##                                coef exp(coef) se(coef)      z     p
## standardized_risk_score      0.1836    1.2015   0.2949  0.623 0.534
## Trt                         -0.2121    0.8089   0.2839 -0.747 0.455
## standardized_risk_score:Trt  0.3793    1.4613   0.3523  1.077 0.282
## 
## Likelihood ratio test=9.58  on 3 df, p=0.02251
## n= 220, number of events= 70

BA4BA5 marker. Three out of the four effect sizes are comparable to each other, but in the Moderna prototype arm there is no association between BA4BA5 marker and risk. This is quite intriguing - if we view each column above as a correlates analysis, we have three positive results and one negative result.

fits=list()
fits[["Pfz,P"]] = coxph(update(f, ~.  + Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0))
fits[["Pfz,O"]] = coxph(update(f, ~.  + Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp, naive==1 & company=="Pfz" & Trt==1))
fits[["Mdn,P"]] = coxph(update(f, ~.  + Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp, naive==1 & company=="Mdn" & Trt==0))
fits[["Mdn,O"]] = coxph(update(f, ~.  + Day15pseudoneutid50_BA.4.BA.5), subset(dat.ocp, naive==1 & company=="Mdn" & Trt==1))
tab = getFormattedSummary(fits, robust=F, type=5)
tab
##                               Pfz,P   Pfz,O   Mdn,P  Mdn,O    
## FOIstandardized               "-0.51" "-0.29" "0.17" "-0.16"  
## standardized_risk_score       "0.25"  "0.44"  "0.16" "0.50**" 
## Day15pseudoneutid50_BA.4.BA.5 "-0.62" "-0.75" "0.00" "-0.76**"

Correlation between ancestral and BA4BA5 ID50s in Pfz,P and Pfz,O separately

par(mfrow=c(1,2))
lim=c(2.5,5.3)
corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0), asp=1, xlim=lim, ylim=lim, main="Pfz, Prototype")
corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.ocp, naive==1 & company=="Pfz" & Trt==1), asp=1, xlim=lim, ylim=lim, main="Pfz, Omicron")

Risk models

ID50 Score

dat$D1_id50=scale(dat$Bpseudoneutid50_MDW,scale=F)
dat$Day15_id50=scale(dat$Day15pseudoneutid50_MDW,scale=F)

coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ FOIstandardized + standardized_risk_score + naive + Day15_id50, dat)
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     FOIstandardized + standardized_risk_score + naive + Day15_id50, 
##     data = dat)
## 
##                              coef exp(coef)  se(coef)      z        p
## FOIstandardized          0.001851  1.001853  0.082550  0.022  0.98211
## standardized_risk_score  0.220804  1.247079  0.084345  2.618  0.00885
## naive                    1.054369  2.870165  0.210874  5.000 5.73e-07
## Day15_id50              -0.371085  0.689986  0.134860 -2.752  0.00593
## 
## Likelihood ratio test=77.26  on 4 df, p=6.61e-16
## n= 985, number of events= 213
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + naive + D1_id50 + Day15_id50 + I(Day15_id50^2), dat)
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + naive + D1_id50 + Day15_id50 + 
##         I(Day15_id50^2), data = dat)
## 
##                             coef exp(coef) se(coef)      z        p
## standardized_risk_score  0.24172   1.27343  0.08176  2.956 0.003112
## naive                    0.66527   1.94501  0.22308  2.982 0.002862
## D1_id50                 -0.44490   0.64089  0.16269 -2.735 0.006245
## Day15_id50              -0.49043   0.61236  0.25055 -1.957 0.050294
## I(Day15_id50^2)         -0.98915   0.37189  0.27479 -3.600 0.000319
## 
## Likelihood ratio test=103.4  on 5 df, p=< 2.2e-16
## n= 985, number of events= 213
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + naive + naive*(D1_id50 + Day15_id50 + I(Day15_id50^2)), dat)
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + naive + naive * (D1_id50 + Day15_id50 + 
##         I(Day15_id50^2)), data = dat)
## 
##                             coef exp(coef) se(coef)      z       p
## standardized_risk_score  0.23644   1.26673  0.08174  2.892 0.00382
## naive                    0.56240   1.75488  0.22961  2.449 0.01431
## D1_id50                 -0.91307   0.40129  0.36906 -2.474 0.01336
## Day15_id50              -0.76230   0.46659  0.56949 -1.339 0.18071
## I(Day15_id50^2)         -0.75581   0.46963  0.46669 -1.620 0.10534
## naive:D1_id50            0.56603   1.76126  0.40890  1.384 0.16628
## naive:Day15_id50         0.33588   1.39917  0.63396  0.530 0.59624
## naive:I(Day15_id50^2)   -0.13493   0.87377  0.55767 -0.242 0.80881
## 
## Likelihood ratio test=108  on 8 df, p=< 2.2e-16
## n= 985, number of events= 213
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + naive + naive*D1_id50 + Day15_id50 + I(Day15_id50^2), dat)
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + naive + naive * D1_id50 + Day15_id50 + 
##         I(Day15_id50^2), data = dat)
## 
##                             coef exp(coef) se(coef)      z        p
## standardized_risk_score  0.23504   1.26496  0.08166  2.878 0.003998
## naive                    0.53717   1.71115  0.21176  2.537 0.011192
## D1_id50                 -1.02753   0.35789  0.30465 -3.373 0.000744
## Day15_id50              -0.47621   0.62113  0.24694 -1.928 0.053804
## I(Day15_id50^2)         -0.88168   0.41409  0.26717 -3.300 0.000966
## naive:D1_id50            0.70604   2.02595  0.32593  2.166 0.030292
## 
## Likelihood ratio test=107.7  on 6 df, p=< 2.2e-16
## n= 985, number of events= 213
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + naive + D1_id50 + naive*Day15_id50 + naive*I(Day15_id50^2), dat)
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + naive + D1_id50 + naive * Day15_id50 + 
##         naive * I(Day15_id50^2), data = dat)
## 
##                             coef exp(coef) se(coef)      z       p
## standardized_risk_score  0.24273   1.27472  0.08174  2.969 0.00298
## naive                    0.63995   1.89639  0.23269  2.750 0.00596
## D1_id50                 -0.44191   0.64281  0.16069 -2.750 0.00596
## Day15_id50              -1.19176   0.30368  0.48297 -2.468 0.01360
## I(Day15_id50^2)         -0.75693   0.46911  0.45572 -1.661 0.09673
## naive:Day15_id50         0.84626   2.33092  0.51659  1.638 0.10139
## naive:I(Day15_id50^2)   -0.14280   0.86693  0.54910 -0.260 0.79482
## 
## Likelihood ratio test=106.2  on 7 df, p=< 2.2e-16
## n= 985, number of events= 213
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + naive + D1_id50 + Day15_id50 + naive*I(Day15_id50^2), dat)
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + naive + D1_id50 + Day15_id50 + 
##         naive * I(Day15_id50^2), data = dat)
## 
##                             coef exp(coef) se(coef)      z       p
## standardized_risk_score  0.24081   1.27228  0.08177  2.945 0.00323
## naive                    0.70910   2.03216  0.24324  2.915 0.00355
## D1_id50                 -0.44461   0.64108  0.16272 -2.732 0.00629
## Day15_id50              -0.52303   0.59272  0.26075 -2.006 0.04487
## I(Day15_id50^2)         -0.70683   0.49321  0.62738 -1.127 0.25990
## naive:I(Day15_id50^2)   -0.34038   0.71150  0.71376 -0.477 0.63345
## 
## Likelihood ratio test=103.6  on 6 df, p=< 2.2e-16
## n= 985, number of events= 213
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + naive + D1_id50 + naive*Day15_id50 + I(Day15_id50^2), dat)
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + naive + D1_id50 + naive * Day15_id50 + 
##         I(Day15_id50^2), data = dat)
## 
##                             coef exp(coef) se(coef)      z       p
## standardized_risk_score  0.24300   1.27507  0.08171  2.974 0.00294
## naive                    0.61857   1.85626  0.21646  2.858 0.00427
## D1_id50                 -0.44083   0.64350  0.16055 -2.746 0.00604
## Day15_id50              -1.21649   0.29627  0.48543 -2.506 0.01221
## I(Day15_id50^2)         -0.86024   0.42306  0.26191 -3.285 0.00102
## naive:Day15_id50         0.88834   2.43109  0.50261  1.767 0.07715
## 
## Likelihood ratio test=106.2  on 6 df, p=< 2.2e-16
## n= 985, number of events= 213

ID50 BA4BA5

dat$D1_id50=scale(dat$Bpseudoneutid50_BA.4.BA.5,scale=F)
dat$Day15_id50=scale(dat$Day15pseudoneutid50_BA.4.BA.5,scale=F)

coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + naive + naive*D1_id50 + Day15_id50 + I(Day15_id50^2), dat)
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + naive + naive * D1_id50 + Day15_id50 + 
##         I(Day15_id50^2), data = dat)
## 
##                            coef exp(coef) se(coef)      z       p
## standardized_risk_score  0.2190    1.2448   0.0811  2.700 0.00694
## naive                    0.4651    1.5921   0.2136  2.177 0.02946
## D1_id50                 -0.9630    0.3818   0.2799 -3.441 0.00058
## Day15_id50              -0.4177    0.6586   0.2126 -1.964 0.04948
## I(Day15_id50^2)         -0.4346    0.6475   0.1563 -2.779 0.00545
## naive:D1_id50            0.6896    1.9930   0.2910  2.370 0.01779
## 
## Likelihood ratio test=106.1  on 6 df, p=< 2.2e-16
## n= 985, number of events= 213
# filter out those with undetectable D1
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + naive + naive*D1_id50 + Day15_id50 + I(Day15_id50^2), subset(dat, D1_id50 > -1.06))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + naive + naive * D1_id50 + Day15_id50 + 
##         I(Day15_id50^2), data = subset(dat, D1_id50 > -1.06))
## 
##                            coef exp(coef) se(coef)      z      p
## standardized_risk_score  0.0757    1.0786   0.1045  0.724 0.4688
## naive                    0.4559    1.5776   0.3107  1.467 0.1423
## D1_id50                 -0.9408    0.3903   0.4848 -1.941 0.0523
## Day15_id50              -0.6463    0.5240   0.2964 -2.180 0.0292
## I(Day15_id50^2)         -0.6404    0.5271   0.3936 -1.627 0.1037
## naive:D1_id50            0.8220    2.2751   0.5404  1.521 0.1282
## 
## Likelihood ratio test=63.51  on 6 df, p=8.688e-12
## n= 699, number of events= 117
# fit model to get inference for D1_id50 in the naive
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + I(1-naive)*D1_id50 + Day15_id50 + I(Day15_id50^2), dat)
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + I(1 - naive) * D1_id50 + Day15_id50 + 
##         I(Day15_id50^2), data = dat)
## 
##                            coef exp(coef) se(coef)      z       p
## standardized_risk_score  0.2190    1.2448   0.0811  2.700 0.00694
## I(1 - naive)            -0.4651    0.6281   0.2136 -2.177 0.02946
## D1_id50                 -0.2733    0.7608   0.1396 -1.958 0.05027
## Day15_id50              -0.4177    0.6586   0.2126 -1.964 0.04948
## I(Day15_id50^2)         -0.4346    0.6475   0.1563 -2.779 0.00545
## I(1 - naive):D1_id50    -0.6896    0.5018   0.2910 -2.370 0.01779
## 
## Likelihood ratio test=106.1  on 6 df, p=< 2.2e-16
## n= 985, number of events= 213
# filter out those with undetectable D1
coxph(Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ standardized_risk_score + I(1-naive)*D1_id50 + Day15_id50 + I(Day15_id50^2), subset(dat, D1_id50 > -1.06))
## Call:
## coxph(formula = Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ 
##     standardized_risk_score + I(1 - naive) * D1_id50 + Day15_id50 + 
##         I(Day15_id50^2), data = subset(dat, D1_id50 > -1.06))
## 
##                            coef exp(coef) se(coef)      z      p
## standardized_risk_score  0.0757    1.0786   0.1045  0.724 0.4688
## I(1 - naive)            -0.4559    0.6339   0.3107 -1.467 0.1423
## D1_id50                 -0.1188    0.8880   0.3228 -0.368 0.7128
## Day15_id50              -0.6463    0.5240   0.2964 -2.180 0.0292
## I(Day15_id50^2)         -0.6404    0.5271   0.3936 -1.627 0.1037
## I(1 - naive):D1_id50    -0.8220    0.4395   0.5404 -1.521 0.1282
## 
## Likelihood ratio test=63.51  on 6 df, p=8.688e-12
## n= 699, number of events= 117

The effect of risk score is different between models with and without double naive (naive and with undetectable D1_id50).

dat$D1_id50=scale(dat$Bpseudoneutid50_BA.4.BA.5,scale=F)

myboxplot(standardized_risk_score~I(1-naive)*I(D1_id50 > -1.06), dat, ylab="standardized_risk_score", names=c("N, D1 undet", "NN, D1 undet", "N, D1 det", "NN, D1 det"))

fit=lm(standardized_risk_score ~ I(1-naive) * I(D1_id50 > -1.06), dat); summary(fit)
## 
## Call:
## lm(formula = standardized_risk_score ~ I(1 - naive) * I(D1_id50 > 
##     -1.06), data = dat)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -5.5176 -0.5421  0.1354  0.6626  2.0105 
## 
## Coefficients:
##                                     Estimate Std. Error t value Pr(>|t|)    
## (Intercept)                          0.03930    0.06026   0.652 0.514516    
## I(1 - naive)                         0.58424    0.29421   1.986 0.047336 *  
## I(D1_id50 > -1.06)TRUE               0.13356    0.08022   1.665 0.096237 .  
## I(1 - naive):I(D1_id50 > -1.06)TRUE -1.15269    0.30374  -3.795 0.000157 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.9976 on 981 degrees of freedom
## Multiple R-squared:  0.06359,    Adjusted R-squared:  0.06073 
## F-statistic: 22.21 on 3 and 981 DF,  p-value: 6.459e-14
fit=lm(standardized_risk_score ~ I(1-naive), subset(dat, D1_id50 <= -1.06)); summary(fit)
## 
## Call:
## lm(formula = standardized_risk_score ~ I(1 - naive), data = subset(dat, 
##     D1_id50 <= -1.06))
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -5.2614 -0.4698  0.1859  0.5916  1.9658 
## 
## Coefficients:
##              Estimate Std. Error t value Pr(>|t|)  
## (Intercept)    0.0393     0.0567   0.693   0.4888  
## I(1 - naive)   0.5842     0.2768   2.111   0.0357 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.9385 on 284 degrees of freedom
## Multiple R-squared:  0.01545,    Adjusted R-squared:  0.01198 
## F-statistic: 4.455 on 1 and 284 DF,  p-value: 0.03566
f=Surv(COVIDtimeD22toD181, COVIDIndD22toD181) ~ FOIstandardized + standardized_risk_score

dat.ocp2=subset(dat_proc, ph1.D15==1 & treatment_assigned %in% c(
    "Wildtype/Prototype (Pfizer 1)"
  , "Omicron (Pfizer 1)"
  , "Omicron + Wildtype/Prototype (Pfizer 1)"
  # , "Omicron BA.4/5 + Prototype (Pfizer 2)"
  # , "Omicron BA.1 + Prototype (Pfizer 2)"
  )
)
dat.ocp2$Trt=ifelse(dat.ocp2$treatment_assigned == "Wildtype/Prototype (Pfizer 1)", 0, 1)

coxph(update(f, ~. + naive + Trt), dat.ocp2)
## Call:
## coxph(formula = update(f, ~. + naive + Trt), data = dat.ocp2)
## 
##                            coef exp(coef) se(coef)      z       p
## FOIstandardized         -0.1126    0.8935   0.2984 -0.377 0.70591
## standardized_risk_score  0.2795    1.3224   0.2878  0.971 0.33154
## naive                    0.8310    2.2955   0.4551  1.826 0.06787
## Trt                     -1.1399    0.3199   0.3749 -3.040 0.00236
## 
## Likelihood ratio test=12.14  on 4 df, p=0.01631
## n= 151, number of events= 30
coxph(update(f, ~. + naive + Trt), subset(dat.ocp2, naive==0))
## Call:
## coxph(formula = update(f, ~. + naive + Trt), data = subset(dat.ocp2, 
##     naive == 0))
## 
##                             coef exp(coef) se(coef)      z     p
## FOIstandardized          0.59531   1.81359  0.61480  0.968 0.333
## standardized_risk_score  0.04664   1.04775  0.52826  0.088 0.930
## naive                         NA        NA  0.00000     NA    NA
## Trt                     -0.52997   0.58862  0.77255 -0.686 0.493
## 
## Likelihood ratio test=1.38  on 3 df, p=0.7098
## n= 53, number of events= 7
coxph(update(f, ~. + naive + Trt), subset(dat.ocp2, naive==1))
## Call:
## coxph(formula = update(f, ~. + naive + Trt), data = subset(dat.ocp2, 
##     naive == 1))
## 
##                            coef exp(coef) se(coef)      z      p
## FOIstandardized         -0.3243    0.7231   0.3318 -0.977 0.3285
## standardized_risk_score  0.4130    1.5113   0.3592  1.150 0.2503
## naive                        NA        NA   0.0000     NA     NA
## Trt                     -1.3346    0.2633   0.4359 -3.062 0.0022
## 
## Likelihood ratio test=10.59  on 3 df, p=0.01415
## n= 98, number of events= 23
dat.1=subset(dat.ocp2, naive==1)

B and D15 marker

table(dat$Bpseudoneutid50_MDWcat, dat$Day15pseudoneutid50_MDWcat)
##              
##               (-Inf,3.62] (3.62,4.07] (4.07, Inf]
##   (-Inf,2.56]         228          80          20
##   (2.56,3.27]          94         155          80
##   (3.27, Inf]           6          94         228
corplot(Day15pseudoneutid50_MDW~Bpseudoneutid50_MDW, dat, col=ifelse(dat$naive==1,1,2))

# fit demming regression
dat.n=subset(dat, naive==1)
dat.nn=subset(dat, naive==0)

fit.n =  Deming(dat.n$Bpseudoneutid50_MDW,  dat.n$Day15pseudoneutid50_MDW,  boot = TRUE)
fit.nn = Deming(dat.nn$Bpseudoneutid50_MDW, dat.nn$Day15pseudoneutid50_MDW, boot = TRUE)

summary(fit.n)
##                                           est    se(est)    (lower    upper)
## Intercept                           1.7871909 0.09110302 1.6060820 1.9576747
## Slope                               0.7210016 0.03387975 0.6587173 0.7917871
## sigma.dat.n$Bpseudoneutid50_MDW     0.2985262 0.01199177 0.2758940 0.3226616
## sigma.dat.n$Day15pseudoneutid50_MDW 0.2985262 0.01199177 0.2758940 0.3226616
##                                           p.value
## Intercept                            1.101506e-85
## Slope                               1.695729e-100
## sigma.dat.n$Bpseudoneutid50_MDW     8.584826e-137
## sigma.dat.n$Day15pseudoneutid50_MDW 8.584826e-137
summary(fit.nn)
##                                            est    se(est)    (lower    upper)
## Intercept                            1.5126849 0.23922704 1.0462625 1.9694045
## Slope                                0.7497295 0.06739409 0.6212233 0.8797335
## sigma.dat.nn$Bpseudoneutid50_MDW     0.2761024 0.01648200 0.2426575 0.3060327
## sigma.dat.nn$Day15pseudoneutid50_MDW 0.2761024 0.01648200 0.2426575 0.3060327
##                                           p.value
## Intercept                            2.561708e-10
## Slope                                9.527661e-29
## sigma.dat.nn$Bpseudoneutid50_MDW     5.497849e-63
## sigma.dat.nn$Day15pseudoneutid50_MDW 5.497849e-63
par(mfrow=c(2,1), mar=c(3,4,2,2))
lim=range(c(dat$Bpseudoneutid50_MDW, dat$Day15pseudoneutid50_MDW))
corplot(Day15pseudoneutid50_MDW~Bpseudoneutid50_MDW, dat.n, add.deming.fit = T, xlim=lim, ylim=lim, xlab="", main="Naive", method="pearson")
corplot(Day15pseudoneutid50_MDW~Bpseudoneutid50_MDW, dat.nn, add.deming.fit = T, xlim=lim, ylim=lim, main="Non-naive", method="pearson")
title(xlab="Bpseudoneutid50_MDW", line=2)

distribution

dat = subset(dat_proc, ph1.D15 & TrtonedosemRNA==1) 

table(dat$Bpseudoneutid50_MDWcat, dat$Day15pseudoneutid50_MDWcat)
##              
##               (-Inf,3.62] (3.62,4.07] (4.07, Inf]
##   (-Inf,2.56]         228          80          20
##   (2.56,3.27]          94         155          80
##   (3.27, Inf]           6          94         228
table(dat$Bpseudoneutid50_MDWcat, dat$Day15pseudoneutid50_MDWcat, dat$naive)
## , ,  = 0
## 
##              
##               (-Inf,3.62] (3.62,4.07] (4.07, Inf]
##   (-Inf,2.56]          11           6           3
##   (2.56,3.27]          24          42          26
##   (3.27, Inf]           5          67         172
## 
## , ,  = 1
## 
##              
##               (-Inf,3.62] (3.62,4.07] (4.07, Inf]
##   (-Inf,2.56]         217          74          17
##   (2.56,3.27]          70         113          54
##   (3.27, Inf]           1          27          56
# all cases have covid lineage observed
mytable(dat_proc$COVIDlineageObserved, dat_proc$COVIDlineage)
##        
##         BA.2 BA.4 BA.5 XBB.1.5 XBB<ca>0.10  XZ <NA>
##   FALSE   23    0   83      13           0   0    0
##   TRUE    62   24  161      15           1   1    0
##   <NA>     0    0    0       0           0   0  857
mytable(dat_proc$COVIDlineageObserved, dat_proc$COVIDIndD22toend)
##        
##           0   1 <NA>
##   FALSE  36  83    0
##   TRUE   60 180   24
##   <NA>  857   0    0

save the risk score from covail_data_processed_20240205.csv as a separate file that will be treated as the source of risk score

dat1=read.csv("/trials/covpn/COVAILcorrelates/analysis/correlates/adata/covail_data_processed_20240205.csv")
write.csv(subset(dat1, select=c(Ptid, risk_score, standardized_risk_score)), row.names=F, file="/trials/covpn/COVAILcorrelates/analysis/correlates/adata/risk_score.csv")

There is a difference in risk score between 0205 and 0206 analysis ready datasets

dat1=read.csv("/trials/covpn/COVAILcorrelates/analysis/mapping_immune_correlates/adata/covail_mapped_data_20240205.csv")
dat2=read.csv("/trials/covpn/COVAILcorrelates/analysis/mapping_immune_correlates/adata/covail_mapped_data_20240206.csv")
nrow(dat1)
nrow(dat2)

cbind(dat1$COVIDIndD22toD181, dat2$COVIDIndD22toD181)[1:100,]


dat1=read.csv("/trials/covpn/COVAILcorrelates/analysis/correlates/adata/covail_data_processed_20240205.csv")
dat2=read.csv("/trials/covpn/COVAILcorrelates/analysis/correlates/adata/covail_data_processed_20240206.csv")
dat3=read.csv("/trials/covpn/COVAILcorrelates/analysis/correlates/adata/covail_data_processed_20240211.csv")
nrow(dat1)
nrow(dat2)
nrow(dat3)

with(subset(dat1,ph1.D15==1), fastauc(risk_score, COVIDIndD22toD181))
with(subset(dat2,ph1.D15==1), fastauc(risk_score, COVIDIndD22toD181))


dat1=read.csv("/trials/covpn/COVAILcorrelates/analysis/mapping_immune_correlates/adata/covail_mapped_data_20240208.csv")
dat2=read.csv("/trials/covpn/COVAILcorrelates/analysis/mapping_immune_correlates/adata/covail_mapped_data_20240211.csv")

rbind(dat1[16,-182],dat2[16,]) # COVIDtimeD22toend

setdiff(names(dat1), names(dat2))

mytable(dat2$COVIDIndD92toD181, dat2$COVIDtimeD92toD181)

sanofi markers

with(dat_mapped, table(treatment_actual %in% c("Beta (Sanofi)", "Beta + Prototype (Sanofi)", "Prototype (Sanofi)"), TrtSanofi))
##        TrtSanofi
##            0    1
##   FALSE 1110    0
##   TRUE     0  152
dat.sanofi = subset(dat_mapped, TrtSanofi==1) #treatment_actual %in% c("Beta (Sanofi)", "Beta + Prototype (Sanofi)", "Prototype (Sanofi)")
summary(dat.sanofi[,c("Day29"%.%assays[1:5])])
##  Day29pseudoneutid50_D614G Day29pseudoneutid50_Delta Day29pseudoneutid50_Beta
##  Min.   :2.964             Min.   :2.761             Min.   :2.450           
##  1st Qu.:3.747             1st Qu.:3.542             1st Qu.:3.413           
##  Median :4.127             Median :3.846             Median :3.813           
##  Mean   :4.118             Mean   :3.892             Mean   :3.821           
##  3rd Qu.:4.457             3rd Qu.:4.260             3rd Qu.:4.238           
##  Max.   :5.195             Max.   :5.036             Max.   :5.136           
##  NA's   :6                 NA's   :6                 NA's   :6               
##  Day29pseudoneutid50_BA.1 Day29pseudoneutid50_BA.4.BA.5
##  Min.   :1.301            Min.   :1.301                
##  1st Qu.:2.769            1st Qu.:2.693                
##  Median :3.322            Median :3.155                
##  Mean   :3.226            Mean   :3.091                
##  3rd Qu.:3.720            3rd Qu.:3.543                
##  Max.   :4.865            Max.   :4.507                
##  NA's   :6                NA's   :6
summary(dat.sanofi[,c("Day15"%.%assays[1:5])])
##  Day15pseudoneutid50_D614G Day15pseudoneutid50_Delta Day15pseudoneutid50_Beta
##  Min.   :2.830             Min.   :2.537             Min.   :2.290           
##  1st Qu.:3.657             1st Qu.:3.325             1st Qu.:3.257           
##  Median :3.922             Median :3.612             Median :3.611           
##  Mean   :3.971             Mean   :3.657             Mean   :3.633           
##  3rd Qu.:4.278             3rd Qu.:3.982             3rd Qu.:4.028           
##  Max.   :4.929             Max.   :4.733             Max.   :4.913           
##  NA's   :6                 NA's   :6                 NA's   :6               
##  Day15pseudoneutid50_BA.1 Day15pseudoneutid50_BA.4.BA.5
##  Min.   :1.301            Min.   :1.301                
##  1st Qu.:2.732            1st Qu.:2.618                
##  Median :3.191            Median :3.021                
##  Mean   :3.204            Mean   :3.002                
##  3rd Qu.:3.612            3rd Qu.:3.489                
##  Max.   :4.612            Max.   :4.493                
##  NA's   :6                NA's   :6
with(subset(dat_mapped, TrtSanofi==1), mytable(naive, COVIDIndD36toD181))
##      COVIDIndD36toD181
## naive  0  1 <NA>
##     0 56  4    2
##     1 66 13   11
with(subset(dat_mapped, TrtSanofi==1), mytable(naive, COVIDIndD22toD181))
##      COVIDIndD22toD181
## naive  0  1 <NA>
##     0 56  4    2
##     1 65 18    7

Correlation is high between BA4BA5 ID50 and ancestral ID50 in both naive and nnaive (higher in the latter)

par(mfrow=c(1,2))
lim=c(2.5,5.3)
corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.sanofi, naive==1), asp=1, xlim=lim, ylim=lim, main="COVAIL Sanofi Naive")
corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, dat.sanofi, asp=1, xlim=lim, ylim=lim, main="COVAIL Sanofi")

# corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.sanofi, naive==0), asp=1, xlim=lim, ylim=lim)

Comparing with Pfz,P in the naive

par(mfrow=c(2,2))
lim=c(1.2,5.5)
myboxplot(list(subset(dat.sanofi, naive==1, Day15pseudoneutid50_D614G, drop=T),
               subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0,Day15pseudoneutid50_D614G, drop=T)), test="w", main="D15 Ancestral ID50", ylim=lim, names=c("Sanofi, naive", "Pfz,P, naive"), ylab="")
myboxplot(list(subset(dat.sanofi, naive==1, Day15pseudoneutid50_BA.4.BA.5, drop=T),
               subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0,Day15pseudoneutid50_BA.4.BA.5, drop=T)), test="w", main="D15 BA4BA5 ID50", ylim=lim, names=c("Sanofi, naive", "Pfz,P, naive"), ylab="")

corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.sanofi, naive==1), asp=1, xlim=lim, ylim=lim, main="Sanofi Naive")
corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0, c(Day15pseudoneutid50_D614G, Day15pseudoneutid50_BA.4.BA.5)), asp=1, xlim=lim, ylim=lim, main="Pfz,P Naive")

Comparing with Pfz,P in the naive, separately by Sanofi,P and Sanofi,NP

par(mfrow=c(1,3))
corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.sanofi, naive==1 & treatment_actual=="Prototype (Sanofi)"), asp=1, xlim=lim, ylim=lim, main="Sanofi,P Naive")
corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.sanofi, naive==1 & treatment_actual!="Prototype (Sanofi)"), asp=1, xlim=lim, ylim=lim, main="Sanofi,NP Naive")
corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0, c(Day15pseudoneutid50_D614G, Day15pseudoneutid50_BA.4.BA.5)), asp=1, xlim=lim, ylim=lim, main="Pfz,P Naive")

Comparing with Pfz,P in the non-naive

par(mfrow=c(2,2))
lim=c(1.2,5.5)
myboxplot(list(subset(dat.sanofi, naive==0, Day15pseudoneutid50_D614G, drop=T),
               subset(dat.ocp, naive==0 & company=="Pfz" & Trt==0,Day15pseudoneutid50_D614G, drop=T)), test="w", main="D15 Ancestral ID50", ylim=lim, names=c("Sanofi, Non-naive", "Pfz,P, Non-naive"), ylab="")
myboxplot(list(subset(dat.sanofi, naive==0, Day15pseudoneutid50_BA.4.BA.5, drop=T),
               subset(dat.ocp, naive==0 & company=="Pfz" & Trt==0,Day15pseudoneutid50_BA.4.BA.5, drop=T)), test="w", main="D15 BA4BA5 ID50", ylim=lim, names=c("Sanofi, Non-naive", "Pfz,P, Non-naive"), ylab="")

corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.sanofi, naive==0), asp=1, xlim=lim, ylim=lim, main="Sanofi Non-naive")
corplot(Day15pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_D614G, subset(dat.ocp, naive==0 & company=="Pfz" & Trt==0, c(Day15pseudoneutid50_D614G, Day15pseudoneutid50_BA.4.BA.5)), asp=1, xlim=lim, ylim=lim, main="Pfz,P Non-naive")

Baseline correlation, in the naive

par(mfrow=c(2,2))
lim=c(1.2,5.5)
myboxplot(list(subset(dat.sanofi, naive==1, Bpseudoneutid50_D614G, drop=T),
               subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0,Bpseudoneutid50_D614G, drop=T)), test="w", main="D1 Ancestral ID50", ylim=lim, names=c("Sanofi, naive", "Pfz,P, naive"), ylab="")
myboxplot(list(subset(dat.sanofi, naive==1, Bpseudoneutid50_BA.4.BA.5, drop=T),
               subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0,Bpseudoneutid50_BA.4.BA.5, drop=T)), test="w", main="D1 BA4BA5 ID50", ylim=lim, names=c("Sanofi, naive", "Pfz,P, naive"), ylab="")

corplot(Bpseudoneutid50_BA.4.BA.5~Bpseudoneutid50_D614G, subset(dat.sanofi, naive==1), asp=1, xlim=lim, ylim=lim, main="Sanofi Naive")
corplot(Bpseudoneutid50_BA.4.BA.5~Bpseudoneutid50_D614G, subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0, c(Bpseudoneutid50_D614G, Bpseudoneutid50_BA.4.BA.5)), asp=1, xlim=lim, ylim=lim, main="Pfz,P Naive")

Baseline correlation, in the non-naive

par(mfrow=c(2,2))
lim=c(1.2,5.5)
myboxplot(list(subset(dat.sanofi, naive==0, Bpseudoneutid50_D614G, drop=T),
               subset(dat.ocp, naive==0 & company=="Pfz" & Trt==0,Bpseudoneutid50_D614G, drop=T)), test="w", main="D1 Ancestral ID50", ylim=lim, names=c("Sanofi, Non-naive", "Pfz,P, Non-naive"), ylab="")
myboxplot(list(subset(dat.sanofi, naive==0, Bpseudoneutid50_BA.4.BA.5, drop=T),
               subset(dat.ocp, naive==0 & company=="Pfz" & Trt==0,Bpseudoneutid50_BA.4.BA.5, drop=T)), test="w", main="D1 BA4BA5 ID50", ylim=lim, names=c("Sanofi, Non-naive", "Pfz,P, Non-naive"), ylab="")

corplot(Bpseudoneutid50_BA.4.BA.5~Bpseudoneutid50_D614G, subset(dat.sanofi, naive==0), asp=1, xlim=lim, ylim=lim, main="Sanofi Non-naive")
corplot(Bpseudoneutid50_BA.4.BA.5~Bpseudoneutid50_D614G, subset(dat.ocp, naive==0 & company=="Pfz" & Trt==0, c(Bpseudoneutid50_D614G, Bpseudoneutid50_BA.4.BA.5)), asp=1, xlim=lim, ylim=lim, main="Pfz,P Non-naive")

Interaction plot, naive

par(mfrow=c(1,2))
lim=c(1.2,4.8)
myboxplot(subset(dat.sanofi, naive==1, c(Day15pseudoneutid50_D614G, Day15pseudoneutid50_BA.4.BA.5)), names=c("ancestral", "BA4BA5"), main="Sanofi, naive", add.interaction=T)
## category.var = x 
## names(dat) = x y z
myboxplot(subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0, c(Day15pseudoneutid50_D614G, Day15pseudoneutid50_BA.4.BA.5)), names=c("ancestral", "BA4BA5"), main="Pfz,P, naive", add.interaction=T)

## category.var = x 
## names(dat) = x y z

Correlation of fold change between ancestral and BA4BA5

dat.sanofi$Day15overBpseudoneutid50_BA.4.BA.5 = dat.sanofi$Day15pseudoneutid50_BA.4.BA.5 - dat.sanofi$Bpseudoneutid50_BA.4.BA.5
dat.sanofi$Day15overBpseudoneutid50_D614G = dat.sanofi$Day15pseudoneutid50_D614G - dat.sanofi$Bpseudoneutid50_D614G
dat.ocp$Day15overBpseudoneutid50_BA.4.BA.5 = dat.ocp$Day15pseudoneutid50_BA.4.BA.5 - dat.ocp$Bpseudoneutid50_BA.4.BA.5
dat.ocp$Day15overBpseudoneutid50_D614G = dat.ocp$Day15pseudoneutid50_D614G - dat.ocp$Bpseudoneutid50_D614G
dat.sanofi$Day29overBpseudoneutid50_BA.4.BA.5 = dat.sanofi$Day29pseudoneutid50_BA.4.BA.5 - dat.sanofi$Bpseudoneutid50_BA.4.BA.5
dat.sanofi$Day29overBpseudoneutid50_D614G = dat.sanofi$Day29pseudoneutid50_D614G - dat.sanofi$Bpseudoneutid50_D614G
dat.ocp$Day29overBpseudoneutid50_BA.4.BA.5 = dat.ocp$Day29pseudoneutid50_BA.4.BA.5 - dat.ocp$Bpseudoneutid50_BA.4.BA.5
dat.ocp$Day29overBpseudoneutid50_D614G = dat.ocp$Day29pseudoneutid50_D614G - dat.ocp$Bpseudoneutid50_D614G

Correlation between D15 over D1 fold change in ancestral and BA4BA5 ID50.

par(mfrow=c(1,3))
lim1=c(0,3.3)
corplot(Day15overBpseudoneutid50_BA.4.BA.5~Day15overBpseudoneutid50_D614G, subset(dat.sanofi, naive==1 & treatment_actual=="Prototype (Sanofi)"), asp=1, xlim=lim1, ylim=lim1, main="Sanofi Prototype Naive")
corplot(Day15overBpseudoneutid50_BA.4.BA.5~Day15overBpseudoneutid50_D614G, subset(dat.sanofi, naive==1 & treatment_actual!="Prototype (Sanofi)" & Day15overBpseudoneutid50_D614G<3), asp=1, xlim=lim1, ylim=lim1, main="Sanofi Beta-containing Naive")
corplot(Day15overBpseudoneutid50_BA.4.BA.5~Day15overBpseudoneutid50_D614G, subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0), asp=1, xlim=lim1, ylim=lim1, main="Pfz,P, naive")

D29 over D1

par(mfrow=c(1,3))
lim1=c(0,3.3)
corplot(Day29overBpseudoneutid50_BA.4.BA.5~Day29overBpseudoneutid50_D614G, subset(dat.sanofi, naive==1 & treatment_actual=="Prototype (Sanofi)"), asp=1, xlim=lim1, ylim=lim1, main="Sanofi Prototype Naive")
corplot(Day29overBpseudoneutid50_BA.4.BA.5~Day29overBpseudoneutid50_D614G, subset(dat.sanofi, naive==1 & treatment_actual!="Prototype (Sanofi)" & Day29overBpseudoneutid50_D614G<3), asp=1, xlim=lim1, ylim=lim1, main="Sanofi Beta-containing Naive")
corplot(Day29overBpseudoneutid50_BA.4.BA.5~Day29overBpseudoneutid50_D614G, subset(dat.ocp, naive==1 & company=="Pfz" & Trt==0), asp=1, xlim=lim1, ylim=lim1, main="Pfz,P, naive")

comparing fold change between different Sanofi arms

par(mfrow=c(1,2))
myboxplot(list(
  subset(dat.sanofi, naive==1 & treatment_actual=="Prototype (Sanofi)", Day15overBpseudoneutid50_BA.4.BA.5, drop=T),
  subset(dat.sanofi, naive==1 & treatment_actual!="Prototype (Sanofi)", Day15overBpseudoneutid50_BA.4.BA.5, drop=T)), test="w", names=c("Prototype", "Non-prototype"))

myboxplot(list(
  subset(dat.sanofi, naive==1 & treatment_actual=="Prototype (Sanofi)", Day15overBpseudoneutid50_D614G, drop=T),
  subset(dat.sanofi, naive==1 & treatment_actual!="Prototype (Sanofi)", Day15overBpseudoneutid50_D614G, drop=T)), test="w", names=c("Prototype", "Non-prototype"))

Comparing D29 and D15. Quite comparable

par(mfrow=c(1,2))
lim1=NULL
corplot(Day29pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_BA.4.BA.5, subset(dat.sanofi, naive==1 & treatment_actual=="Prototype (Sanofi)"), asp=1, xlim=lim1, ylim=lim1, main="Sanofi,P Naive")
corplot(Day29pseudoneutid50_BA.4.BA.5~Day15pseudoneutid50_BA.4.BA.5, subset(dat.sanofi, naive==1 & treatment_actual!="Prototype (Sanofi)"), asp=1, xlim=lim1, ylim=lim1, main="Sanofi,NP Naive")

correlation between m15 and baseline markers

dat=subset(dat_proc, ph1.D15 & TrtonedosemRNA==1) 

mypairs(dat[,paste0("B",assays)])

mypairs(dat[,paste0("Day15",assays)])

mypairs(dat[,paste0(c("B","Day15", "Delta15overB"),assays[1])])

marker missingness

table(dat_proc$AsympInfectIndD15to29, dat_proc$ph1.D15)
##    
##        0    1
##   0  110 1116
##   1    3   11
table(dat_proc$arm, dat_proc$ph1.D15)
##     
##        0   1
##   1    1  96
##   2    3 109
##   3   85   0
##   4    2  98
##   5    3  96
##   6    4  92
##   7    0  47
##   8    1  50
##   9    1  52
##   10   2  49
##   11   2  49
##   12   0  52
##   13   1  45
##   14   2  48
##   15   1  49
##   16   2  98
##   17   3  97
table(dat_mapped$ph1.D15, dat_mapped$Immunemarkerset, dat_mapped$arm==3)
## , ,  = FALSE
## 
##    
##        0    1
##   0   49    0
##   1    0 1127
## 
## , ,  = TRUE
## 
##    
##        0    1
##   0    1   85
##   1    0    0
# across assays, all or none
summary(subset(dat_mapped, ph1.D15==1)["Day15"%.%assays[1:5]])
##  Day15pseudoneutid50_D614G Day15pseudoneutid50_Delta Day15pseudoneutid50_Beta
##  Min.   :1.301             Min.   :1.301             Min.   :1.301           
##  1st Qu.:4.039             1st Qu.:3.739             1st Qu.:3.643           
##  Median :4.348             Median :4.069             Median :4.035           
##  Mean   :4.311             Mean   :4.050             Mean   :3.999           
##  3rd Qu.:4.627             3rd Qu.:4.396             3rd Qu.:4.414           
##  Max.   :5.666             Max.   :5.381             Max.   :5.592           
##                                                                              
##  Day15pseudoneutid50_BA.1 Day15pseudoneutid50_BA.4.BA.5
##  Min.   :1.301            Min.   :1.301                
##  1st Qu.:3.238            1st Qu.:2.954                
##  Median :3.636            Median :3.379                
##  Mean   :3.615            Mean   :3.335                
##  3rd Qu.:4.050            3rd Qu.:3.786                
##  Max.   :5.225            Max.   :5.361                
##                           NA's   :666
summary(subset(dat_mapped, ph1.D15==1)["Day29"%.%assays[1:5]])
##  Day29pseudoneutid50_D614G Day29pseudoneutid50_Delta Day29pseudoneutid50_Beta
##  Min.   :1.301             Min.   :1.301             Min.   :1.301           
##  1st Qu.:3.985             1st Qu.:3.687             1st Qu.:3.544           
##  Median :4.281             Median :4.002             Median :3.938           
##  Mean   :4.265             Mean   :3.993             Mean   :3.912           
##  3rd Qu.:4.570             3rd Qu.:4.320             3rd Qu.:4.312           
##  Max.   :5.605             Max.   :5.402             Max.   :5.414           
##  NA's   :15                NA's   :15                NA's   :15              
##  Day29pseudoneutid50_BA.1 Day29pseudoneutid50_BA.4.BA.5
##  Min.   :1.301            Min.   :1.301                
##  1st Qu.:3.114            1st Qu.:2.889                
##  Median :3.513            Median :3.272                
##  Mean   :3.482            Mean   :3.232                
##  3rd Qu.:3.894            3rd Qu.:3.649                
##  Max.   :5.326            Max.   :4.907                
##  NA's   :16               NA's   :15
summary(subset(dat_mapped, ph1.D15==1)["Day91"%.%assays[1:5]])
##  Day91pseudoneutid50_D614G Day91pseudoneutid50_Delta Day91pseudoneutid50_Beta
##  Min.   :1.301             Min.   :1.301             Min.   :1.301           
##  1st Qu.:3.768             1st Qu.:3.474             1st Qu.:3.337           
##  Median :4.115             Median :3.818             Median :3.729           
##  Mean   :4.100             Mean   :3.807             Mean   :3.724           
##  3rd Qu.:4.457             3rd Qu.:4.164             3rd Qu.:4.170           
##  Max.   :5.624             Max.   :5.438             Max.   :5.420           
##  NA's   :27                NA's   :27                NA's   :27              
##  Day91pseudoneutid50_BA.1 Day91pseudoneutid50_BA.4.BA.5
##  Min.   :1.301            Min.   :1.301                
##  1st Qu.:2.937            1st Qu.:2.715                
##  Median :3.396            Median :3.169                
##  Mean   :3.337            Mean   :3.121                
##  3rd Qu.:3.779            3rd Qu.:3.611                
##  Max.   :5.190            Max.   :4.975                
##  NA's   :27               NA's   :27
summary(subset(dat_mapped, ph1.D15==1)["Day181"%.%assays[1:5]])
##  Day181pseudoneutid50_D614G Day181pseudoneutid50_Delta
##  Min.   :1.301              Min.   :1.301             
##  1st Qu.:3.639              1st Qu.:3.282             
##  Median :3.980              Median :3.646             
##  Mean   :3.960              Mean   :3.617             
##  3rd Qu.:4.338              3rd Qu.:3.970             
##  Max.   :5.601              Max.   :5.118             
##  NA's   :59                 NA's   :59                
##  Day181pseudoneutid50_Beta Day181pseudoneutid50_BA.1
##  Min.   :1.301             Min.   :1.301            
##  1st Qu.:3.135             1st Qu.:2.852            
##  Median :3.602             Median :3.286            
##  Mean   :3.551             Mean   :3.229            
##  3rd Qu.:3.997             3rd Qu.:3.738            
##  Max.   :5.298             Max.   :5.228            
##  NA's   :59                NA's   :59               
##  Day181pseudoneutid50_BA.4.BA.5
##  Min.   :1.301                 
##  1st Qu.:2.603                 
##  Median :3.124                 
##  Mean   :3.056                 
##  3rd Qu.:3.591                 
##  Max.   :4.913                 
##  NA's   :59
summary(subset(dat_proc, ph1.D15 & is.na(Day29pseudoneutid50_D614G))["Day29"%.%assays[1:5]])
##  Day29pseudoneutid50_D614G Day29pseudoneutid50_Delta Day29pseudoneutid50_Beta
##  Min.   : NA               Min.   : NA               Min.   : NA             
##  1st Qu.: NA               1st Qu.: NA               1st Qu.: NA             
##  Median : NA               Median : NA               Median : NA             
##  Mean   :NaN               Mean   :NaN               Mean   :NaN             
##  3rd Qu.: NA               3rd Qu.: NA               3rd Qu.: NA             
##  Max.   : NA               Max.   : NA               Max.   : NA             
##  NA's   :15                NA's   :15                NA's   :15              
##  Day29pseudoneutid50_BA.1 Day29pseudoneutid50_BA.4.BA.5
##  Min.   : NA              Min.   : NA                  
##  1st Qu.: NA              1st Qu.: NA                  
##  Median : NA              Median : NA                  
##  Mean   :NaN              Mean   :NaN                  
##  3rd Qu.: NA              3rd Qu.: NA                  
##  Max.   : NA              Max.   : NA                  
##  NA's   :15               NA's   :15
summary(subset(dat_proc, ph1.D15 & is.na(Day91pseudoneutid50_D614G))["Day91"%.%assays[1:5]])
##  Day91pseudoneutid50_D614G Day91pseudoneutid50_Delta Day91pseudoneutid50_Beta
##  Min.   : NA               Min.   : NA               Min.   : NA             
##  1st Qu.: NA               1st Qu.: NA               1st Qu.: NA             
##  Median : NA               Median : NA               Median : NA             
##  Mean   :NaN               Mean   :NaN               Mean   :NaN             
##  3rd Qu.: NA               3rd Qu.: NA               3rd Qu.: NA             
##  Max.   : NA               Max.   : NA               Max.   : NA             
##  NA's   :27                NA's   :27                NA's   :27              
##  Day91pseudoneutid50_BA.1 Day91pseudoneutid50_BA.4.BA.5
##  Min.   : NA              Min.   : NA                  
##  1st Qu.: NA              1st Qu.: NA                  
##  Median : NA              Median : NA                  
##  Mean   :NaN              Mean   :NaN                  
##  3rd Qu.: NA              3rd Qu.: NA                  
##  Max.   : NA              Max.   : NA                  
##  NA's   :27               NA's   :27
summary(subset(dat_proc, ph1.D15 & is.na(Day181pseudoneutid50_D614G))["Day181"%.%assays[1:5]])
##  Day181pseudoneutid50_D614G Day181pseudoneutid50_Delta
##  Min.   : NA                Min.   : NA               
##  1st Qu.: NA                1st Qu.: NA               
##  Median : NA                Median : NA               
##  Mean   :NaN                Mean   :NaN               
##  3rd Qu.: NA                3rd Qu.: NA               
##  Max.   : NA                Max.   : NA               
##  NA's   :59                 NA's   :59                
##  Day181pseudoneutid50_Beta Day181pseudoneutid50_BA.1
##  Min.   : NA               Min.   : NA              
##  1st Qu.: NA               1st Qu.: NA              
##  Median : NA               Median : NA              
##  Mean   :NaN               Mean   :NaN              
##  3rd Qu.: NA               3rd Qu.: NA              
##  Max.   : NA               Max.   : NA              
##  NA's   :59                NA's   :59               
##  Day181pseudoneutid50_BA.4.BA.5
##  Min.   : NA                   
##  1st Qu.: NA                   
##  Median : NA                   
##  Mean   :NaN                   
##  3rd Qu.: NA                   
##  Max.   : NA                   
##  NA's   :59
dat_proc$kp = dat_proc$ph1.D15==1 & dat_proc$COVIDIndD22toend!=1 & dat_proc$AsympInfectIndD15to271!=1 
dat_proc$kp = dat_proc$ph1.D15==1 
for (i in 1:1) {
  with(dat_proc[dat_proc$kp,], print(table(!is.na(get("Day29"%.%assays[i])), !is.na(get("Day15"%.%assays[i])))))
  with(dat_proc[dat_proc$kp,], print(table(!is.na(get("Day91"%.%assays[i])), !is.na(get("Day15"%.%assays[i])))))
  with(dat_proc[dat_proc$kp,], print(table(!is.na(get("Day181"%.%assays[i])), !is.na(get("Day15"%.%assays[i])))))
}
##        
##         TRUE
##   FALSE   15
##   TRUE  1112
##        
##         TRUE
##   FALSE   27
##   TRUE  1100
##        
##         TRUE
##   FALSE   59
##   TRUE  1068
myboxplot(
list(dat_proc$Day15pseudoneutid50_MDW[dat_proc$treatment_actual=="Omicron + Wildtype/Prototype (Pfizer 1)"], 
     dat_proc$Day15pseudoneutid50_MDW[dat_proc$treatment_actual=="1 Dose Omicron + Prototype (Moderna)"])
)

myboxplot(
  list(dat_proc$Day15pseudoneutid50_D614G[dat_proc$treatment_actual=="Omicron + Wildtype/Prototype (Pfizer 1)"], 
       dat_proc$Day15pseudoneutid50_D614G[dat_proc$treatment_actual=="1 Dose Omicron + Prototype (Moderna)"])
)

# my.interaction.plot(subset(dat_proc, ph1==1, 
#                            c(Bpseudoneutid50_BA.1, Day15pseudoneutid50_BA.1)), 
#                     x.ori = 0, xaxislabels = c("B", "D15"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  
# 
# my.interaction.plot(subset(dat_proc, ph1==1, 
#                            c(Day15pseudoneutid50_BA.1, Day29pseudoneutid50_BA.1)), 
#                     x.ori = 1, xaxislabels = c("D15", "D29"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  
# 
# my.interaction.plot(subset(dat_proc, ph1==1, 
#                            c(Day29pseudoneutid50_BA.1, Day91pseudoneutid50_BA.1)), 
#                     x.ori = 2, xaxislabels = c("D29", "D91"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  
# 
# my.interaction.plot(subset(dat_proc, ph1==1, 
#                            c(Day91pseudoneutid50_BA.1, Day181pseudoneutid50_BA.1)), 
#                     x.ori = 3, xaxislabels = c("D91", "D181"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  
# 

marker level over time

par(mfrow=c(4,1), mar=c(2,4,1,1))

dat_proc$ph1 = dat_proc$ph1.D15==1 & dat_proc$COVIDIndD22toend!=1 & dat_proc$AsympInfectIndD15to181!=1 & dat_proc$AsympInfectIndD182to271!=1

plot(0,0,type='n', xlim=c(1,5), ylim=c(1,5), xaxt="n", xlab="", ylab="ID50_BA.1")

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1<1.5, 
                           c(Bpseudoneutid50_BA.1, Day15pseudoneutid50_BA.1)), 
                    x.ori = 0, xaxislabels = c("B", "D15"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1<1.5, 
                           c(Day15pseudoneutid50_BA.1, Day29pseudoneutid50_BA.1)), 
                    x.ori = 1, xaxislabels = c("D15", "D29"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1<1.5, 
                           c(Day29pseudoneutid50_BA.1, Day91pseudoneutid50_BA.1)), 
                    x.ori = 2, xaxislabels = c("D29", "D91"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1<1.5, 
                           c(Day91pseudoneutid50_BA.1, Day181pseudoneutid50_BA.1)), 
                    x.ori = 3, xaxislabels = c("D91", "D181"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  


plot(0,0,type='n', xlim=c(1,5), ylim=c(1,5), xaxt="n", xlab="", ylab="ID50_BA.1")

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1>1.5, 
                           c(Bpseudoneutid50_BA.1, Day15pseudoneutid50_BA.1)), 
                    x.ori = 0, xaxislabels = c("B", "D15"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1>1.5, 
                           c(Day15pseudoneutid50_BA.1, Day29pseudoneutid50_BA.1)), 
                    x.ori = 1, xaxislabels = c("D15", "D29"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1>1.5, 
                           c(Day29pseudoneutid50_BA.1, Day91pseudoneutid50_BA.1)), 
                    x.ori = 2, xaxislabels = c("D29", "D91"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1>1.5, 
                           c(Day91pseudoneutid50_BA.1, Day181pseudoneutid50_BA.1)), 
                    x.ori = 3, xaxislabels = c("D91", "D181"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  



dat_proc$ph1 = dat_proc$ph1.D92 & dat_proc$ph1.D15==1 & dat_proc$COVIDIndD22toend!=1 & dat_proc$AsympInfectIndD15to181!=1 & dat_proc$AsympInfectIndD182to271!=1

plot(0,0,type='n', xlim=c(1,5), ylim=c(1,5), xaxt="n", xlab="", ylab="ID50_BA.1")

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1<1.5, 
                           c(Bpseudoneutid50_BA.1, Day15pseudoneutid50_BA.1)), 
                    x.ori = 0, xaxislabels = c("B", "D15"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1<1.5, 
                           c(Day15pseudoneutid50_BA.1, Day29pseudoneutid50_BA.1)), 
                    x.ori = 1, xaxislabels = c("D15", "D29"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1<1.5, 
                           c(Day29pseudoneutid50_BA.1, Day91pseudoneutid50_BA.1)), 
                    x.ori = 2, xaxislabels = c("D29", "D91"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1<1.5, 
                           c(Day91pseudoneutid50_BA.1, Day181pseudoneutid50_BA.1)), 
                    x.ori = 3, xaxislabels = c("D91", "D181"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  


plot(0,0,type='n', xlim=c(1,5), ylim=c(1,5), xaxt="n", xlab="", ylab="ID50_BA.1")

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1>1.5, 
                           c(Bpseudoneutid50_BA.1, Day15pseudoneutid50_BA.1)), 
                    x.ori = 0, xaxislabels = c("B", "D15"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1>1.5, 
                           c(Day15pseudoneutid50_BA.1, Day29pseudoneutid50_BA.1)), 
                    x.ori = 1, xaxislabels = c("D15", "D29"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1>1.5, 
                           c(Day29pseudoneutid50_BA.1, Day91pseudoneutid50_BA.1)), 
                    x.ori = 2, xaxislabels = c("D29", "D91"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

my.interaction.plot(subset(dat_proc, ph1==1 & Bpseudoneutid50_BA.1>1.5, 
                           c(Day91pseudoneutid50_BA.1, Day181pseudoneutid50_BA.1)), 
                    x.ori = 3, xaxislabels = c("D91", "D181"), cex.axis = 1, add = T, xlab = "", ylab = "", pcol = NULL, lcol = NULL)  

sum(dat_proc$ph1.D15==1)
## [1] 1127
dat_proc$kp = dat_proc$ph1.D15==1 & dat_proc$COVIDIndD22toend!=1 & dat_proc$AsympInfectIndD15to271!=1 &
  !is.na(dat_proc$Day29pseudoneutid50_D614G) & !is.na(dat_proc$Day91pseudoneutid50_D614G) & !is.na(dat_proc$Day181pseudoneutid50_D614G) 

nrow(subset(dat_proc, kp))
## [1] 733
nrow(subset(dat_proc, kp & Bpseudoneutid50_BA.1>1.5))
## [1] 619
nrow(subset(dat_proc, kp & Bpseudoneutid50_BA.1<1.5))
## [1] 114

Misc

myboxplot(dat_mapped[, c("B"%.%assays[1:5], "Day15"%.%assays[1:5])], names=sub("pseudoneutid50_", "", rep(assays[1:5],2)))

summary(dat_mapped)
##   Subjectid         EthnicityHispanic EthnicityNotreported     race          
##  Length:1262        Min.   :0.00000   Min.   :0.0000000    Length:1262       
##  Class :character   1st Qu.:0.00000   1st Qu.:0.0000000    Class :character  
##  Mode  :character   Median :0.00000   Median :0.0000000    Mode  :character  
##                     Mean   :0.09113   Mean   :0.0007924                      
##                     3rd Qu.:0.00000   3rd Qu.:0.0000000                      
##                     Max.   :1.00000   Max.   :1.0000000                      
##                                                                              
##      Asian            Black            NatAmer            PacIsl        
##  Min.   :0.0000   Min.   :0.00000   Min.   :0.00000   Min.   :0.000000  
##  1st Qu.:0.0000   1st Qu.:0.00000   1st Qu.:0.00000   1st Qu.:0.000000  
##  Median :0.0000   Median :0.00000   Median :0.00000   Median :0.000000  
##  Mean   :0.1173   Mean   :0.09033   Mean   :0.01426   Mean   :0.001585  
##  3rd Qu.:0.0000   3rd Qu.:0.00000   3rd Qu.:0.00000   3rd Qu.:0.000000  
##  Max.   :1.0000   Max.   :1.00000   Max.   :1.00000   Max.   :1.000000  
##                                                                         
##      White         Multiracial         Unknown              Age       
##  Min.   :0.0000   Min.   :0.00000   Min.   :0.000000   Min.   :18.00  
##  1st Qu.:1.0000   1st Qu.:0.00000   1st Qu.:0.000000   1st Qu.:33.00  
##  Median :1.0000   Median :0.00000   Median :0.000000   Median :45.00  
##  Mean   :0.8035   Mean   :0.03487   Mean   :0.009509   Mean   :47.66  
##  3rd Qu.:1.0000   3rd Qu.:0.00000   3rd Qu.:0.000000   3rd Qu.:65.00  
##  Max.   :1.0000   Max.   :1.00000   Max.   :1.000000   Max.   :85.00  
##                                                                       
##      Age65C          State               City                Sex        
##  Min.   :0.0000   Length:1262        Length:1262        Min.   :0.0000  
##  1st Qu.:0.0000   Class :character   Class :character   1st Qu.:0.0000  
##  Median :0.0000   Mode  :character   Mode  :character   Median :1.0000  
##  Mean   :0.2647                                         Mean   :0.5452  
##  3rd Qu.:1.0000                                         3rd Qu.:1.0000  
##  Max.   :1.0000                                         Max.   :1.0000  
##                                                                         
##      naive        eligibility_deviation early_term_date    oos_boost_date    
##  Min.   :0.0000   Length:1262           Length:1262        Length:1262       
##  1st Qu.:0.0000   Class :character      Class :character   Class :character  
##  Median :1.0000   Mode  :character      Mode  :character   Mode  :character  
##  Mean   :0.6513                                                              
##  3rd Qu.:1.0000                                                              
##  Max.   :1.0000                                                              
##                                                                              
##      RESULT        RESULT_limit          UNITS              ASSAY          
##  Min.   :   41.0   Length:1262        Length:1262        Length:1262       
##  1st Qu.:  251.5   Class :character   Class :character   Class :character  
##  Median :  646.0   Mode  :character   Mode  :character   Mode  :character  
##  Mean   : 2117.9                                                           
##  3rd Qu.: 2093.8                                                           
##  Max.   :48003.0                                                           
##  NA's   :238                                                               
##      stage       treatment_actual   treatment_assigned  stratalab        
##  Min.   :1.000   Length:1262        Length:1262        Length:1262       
##  1st Qu.:1.000   Class :character   Class :character   Class :character  
##  Median :2.000   Mode  :character   Mode  :character   Mode  :character  
##  Mean   :1.966                                                           
##  3rd Qu.:3.000                                                           
##  Max.   :4.000                                                           
##                                                                          
##  primary_vax1_date  primary_vax2_date  pre_study_booster_date
##  Length:1262        Length:1262        Length:1262           
##  Class :character   Class :character   Class :character      
##  Mode  :character   Mode  :character   Mode  :character      
##                                                              
##                                                              
##                                                              
##                                                              
##  primary_booster_type pre_study_infect_date studydose1date    
##  Length:1262          Length:1262           Length:1262       
##  Class :character     Class :character      Class :character  
##  Mode  :character     Mode  :character      Mode  :character  
##                                                               
##                                                               
##                                                               
##                                                               
##  studydose2date      early_term         oos_boost         infect_date1      
##  Length:1262        Length:1262        Length:1262        Length:1262       
##  Class :character   Class :character   Class :character   Class :character  
##  Mode  :character   Mode  :character   Mode  :character   Mode  :character  
##                                                                             
##                                                                             
##                                                                             
##                                                                             
##  infect_date2       symptomatic_infect1 symptomatic_infect2  NAntibody        
##  Length:1262        Length:1262         Length:1262         Length:1262       
##  Class :character   Class :character    Class :character    Class :character  
##  Mode  :character   Mode  :character    Mode  :character    Mode  :character  
##                                                                               
##                                                                               
##                                                                               
##                                                                               
##   CTSTAT_SWAB1 CTVALUE_SWAB1   ASSSTAT_SWAB1   ASSQC_SWAB1       
##  Min.   :1     Min.   :14.00   Min.   :1.000   Length:1262       
##  1st Qu.:1     1st Qu.:19.70   1st Qu.:1.000   Class :character  
##  Median :1     Median :22.40   Median :1.000   Mode  :character  
##  Mean   :1     Mean   :22.80   Mean   :1.022                     
##  3rd Qu.:1     3rd Qu.:25.75   3rd Qu.:1.000                     
##  Max.   :1     Max.   :32.80   Max.   :2.000                     
##  NA's   :983   NA's   :983     NA's   :983                       
##  TOTREADS_SWAB1   COVRDPCT_SWAB1  HSTRDPCT_SWAB1   BACRDPCT_SWAB1   
##  Min.   : 38148   Min.   : 5.64   Min.   : 0.000   Min.   : 0.0000  
##  1st Qu.:239706   1st Qu.:95.51   1st Qu.: 0.040   1st Qu.: 0.0600  
##  Median :317509   Median :97.23   Median : 0.140   Median : 0.1100  
##  Mean   :312744   Mean   :95.57   Mean   : 1.228   Mean   : 0.3963  
##  3rd Qu.:383596   3rd Qu.:98.36   3rd Qu.: 0.905   3rd Qu.: 0.3650  
##  Max.   :764242   Max.   :99.22   Max.   :29.430   Max.   :40.7300  
##  NA's   :983      NA's   :983     NA's   :983      NA's   :983      
##  ASSCOMP_SWAB1    PANGOLIN_SWAB1     PANGOVER_SWAB1     SCORCALL_SWAB1    
##  Min.   :0.7400   Length:1262        Length:1262        Length:1262       
##  1st Qu.:0.9900   Class :character   Class :character   Class :character  
##  Median :0.9900   Mode  :character   Mode  :character   Mode  :character  
##  Mean   :0.9834                                                           
##  3rd Qu.:0.9900                                                           
##  Max.   :0.9900                                                           
##  NA's   :983                                                              
##  SCORVER_SWAB1      TRUNCLIN_SWAB1     TRUNCVER_SWAB1     SPKAASUB_SWAB1    
##  Length:1262        Length:1262        Length:1262        Length:1262       
##  Class :character   Class :character   Class :character   Class :character  
##  Mode  :character   Mode  :character   Mode  :character   Mode  :character  
##                                                                             
##                                                                             
##                                                                             
##                                                                             
##  SPKAADEL_SWAB1     SPKAAINS_SWAB1 DATE_COLLECT_SWAB1  CTSTAT_SWAB2 
##  Length:1262        Mode:logical   Length:1262        Min.   :1     
##  Class :character   NA's:1262      Class :character   1st Qu.:1     
##  Mode  :character                  Mode  :character   Median :1     
##                                                       Mean   :1     
##                                                       3rd Qu.:1     
##                                                       Max.   :1     
##                                                       NA's   :1261  
##  CTVALUE_SWAB2  ASSSTAT_SWAB2  ASSQC_SWAB2        TOTREADS_SWAB2 
##  Min.   :24.8   Min.   :1      Length:1262        Min.   :94834  
##  1st Qu.:24.8   1st Qu.:1      Class :character   1st Qu.:94834  
##  Median :24.8   Median :1      Mode  :character   Median :94834  
##  Mean   :24.8   Mean   :1                         Mean   :94834  
##  3rd Qu.:24.8   3rd Qu.:1                         3rd Qu.:94834  
##  Max.   :24.8   Max.   :1                         Max.   :94834  
##  NA's   :1261   NA's   :1261                      NA's   :1261   
##  COVRDPCT_SWAB2  HSTRDPCT_SWAB2 BACRDPCT_SWAB2 ASSCOMP_SWAB2 
##  Min.   :97.38   Min.   :0.71   Min.   :0.61   Min.   :0.99  
##  1st Qu.:97.38   1st Qu.:0.71   1st Qu.:0.61   1st Qu.:0.99  
##  Median :97.38   Median :0.71   Median :0.61   Median :0.99  
##  Mean   :97.38   Mean   :0.71   Mean   :0.61   Mean   :0.99  
##  3rd Qu.:97.38   3rd Qu.:0.71   3rd Qu.:0.61   3rd Qu.:0.99  
##  Max.   :97.38   Max.   :0.71   Max.   :0.61   Max.   :0.99  
##  NA's   :1261    NA's   :1261   NA's   :1261   NA's   :1261  
##  PANGOLIN_SWAB2     PANGOVER_SWAB2     SCORCALL_SWAB2     SCORVER_SWAB2     
##  Length:1262        Length:1262        Length:1262        Length:1262       
##  Class :character   Class :character   Class :character   Class :character  
##  Mode  :character   Mode  :character   Mode  :character   Mode  :character  
##                                                                             
##                                                                             
##                                                                             
##                                                                             
##  TRUNCLIN_SWAB2     TRUNCVER_SWAB2     SPKAASUB_SWAB2     SPKAADEL_SWAB2    
##  Length:1262        Length:1262        Length:1262        Length:1262       
##  Class :character   Class :character   Class :character   Class :character  
##  Mode  :character   Mode  :character   Mode  :character   Mode  :character  
##                                                                             
##                                                                             
##                                                                             
##                                                                             
##  SPKAAINS_SWAB2 DATE_COLLECT_SWAB2    TrtmRNA            arm        
##  Mode:logical   Length:1262        Min.   :0.0000   Min.   : 1.000  
##  NA's:1262      Class :character   1st Qu.:1.0000   1st Qu.: 4.000  
##                 Mode  :character   Median :1.0000   Median : 7.000  
##                                    Mean   :0.8796   Mean   : 8.315  
##                                    3rd Qu.:1.0000   3rd Qu.:13.000  
##                                    Max.   :1.0000   Max.   :17.000  
##                                                                     
##       TrtA             TrtB             TrtC        TrtonedosemRNA  
##  Min.   :0.0000   Min.   :0.0000   Min.   :0.0000   Min.   :0.0000  
##  1st Qu.:0.0000   1st Qu.:0.0000   1st Qu.:1.0000   1st Qu.:1.0000  
##  Median :1.0000   Median :0.0000   Median :1.0000   Median :1.0000  
##  Mean   :0.6624   Mean   :0.1618   Mean   :0.8018   Mean   :0.8114  
##  3rd Qu.:1.0000   3rd Qu.:0.0000   3rd Qu.:1.0000   3rd Qu.:1.0000  
##  Max.   :1.0000   Max.   :1.0000   Max.   :1.0000   Max.   :1.0000  
##  NA's   :643      NA's   :341      NA's   :490                      
##    TrtSanofi      pre_study_booster_until_studydose1_day
##  Min.   :0.0000   Min.   : 11.0                         
##  1st Qu.:0.0000   1st Qu.:164.0                         
##  Median :0.0000   Median :191.0                         
##  Mean   :0.1204   Mean   :207.7                         
##  3rd Qu.:0.0000   3rd Qu.:230.0                         
##  Max.   :1.0000   Max.   :592.0                         
##                                                         
##  pre_study_booster_until_studydose1_day_median
##  Min.   :191                                  
##  1st Qu.:191                                  
##  Median :191                                  
##  Mean   :191                                  
##  3rd Qu.:191                                  
##  Max.   :191                                  
##                                               
##  pre_study_booster_until_studydose1_ind  D1_D15_flag      D1_D29_flag    
##  Min.   :0.0000                         Min.   :0.0000   Min.   :0.0000  
##  1st Qu.:0.0000                         1st Qu.:1.0000   1st Qu.:1.0000  
##  Median :0.0000                         Median :1.0000   Median :1.0000  
##  Mean   :0.4984                         Mean   :0.9818   Mean   :0.9802  
##  3rd Qu.:1.0000                         3rd Qu.:1.0000   3rd Qu.:1.0000  
##  Max.   :1.0000                         Max.   :1.0000   Max.   :1.0000  
##                                                                          
##  Bpseudoneutid50_BA.1 Bpseudoneutid50_Beta Bpseudoneutid50_Delta
##  Min.   :1.301        Min.   :1.301        Min.   :1.301        
##  1st Qu.:2.072        1st Qu.:2.590        1st Qu.:2.904        
##  Median :2.612        Median :3.130        Median :3.357        
##  Mean   :2.583        Mean   :3.072        Mean   :3.315        
##  3rd Qu.:3.181        3rd Qu.:3.606        3rd Qu.:3.775        
##  Max.   :4.681        Max.   :4.917        Max.   :4.893        
##  NA's   :1            NA's   :1            NA's   :1            
##  Bpseudoneutid50Duke_BA.2.12.1 Bpseudoneutid50_BA.4.BA.5 Bpseudoneutid50_D614G
##  Min.   :1.301                 Min.   :1.301             Min.   :1.301        
##  1st Qu.:2.041                 1st Qu.:1.301             1st Qu.:3.257        
##  Median :2.394                 Median :2.425             Median :3.649        
##  Mean   :2.396                 Mean   :2.341             Mean   :3.636        
##  3rd Qu.:2.833                 3rd Qu.:2.990             3rd Qu.:4.096        
##  Max.   :4.235                 Max.   :4.385             Max.   :5.084        
##  NA's   :1137                  NA's   :1                 NA's   :1            
##  Day15pseudoneutid50_BA.1 Day15pseudoneutid50_Beta Day15pseudoneutid50_Delta
##  Min.   :1.301            Min.   :1.301            Min.   :1.301            
##  1st Qu.:3.239            1st Qu.:3.648            1st Qu.:3.734            
##  Median :3.631            Median :4.035            Median :4.067            
##  Mean   :3.613            Mean   :4.000            Mean   :4.044            
##  3rd Qu.:4.053            3rd Qu.:4.415            3rd Qu.:4.391            
##  Max.   :5.225            Max.   :5.592            Max.   :5.381            
##  NA's   :22               NA's   :22               NA's   :22               
##  Day15pseudoneutid50Duke_BA.2.12.1 Day15pseudoneutid50_BA.4.BA.5
##  Min.   :1.301                     Min.   :1.301                
##  1st Qu.:3.078                     1st Qu.:2.952                
##  Median :3.382                     Median :3.380                
##  Mean   :3.390                     Mean   :3.335                
##  3rd Qu.:3.695                     3rd Qu.:3.784                
##  Max.   :4.859                     Max.   :5.361                
##  NA's   :1137                      NA's   :791                  
##  Day15pseudoneutid50_D614G Day29pseudoneutid50_BA.1 Day29pseudoneutid50_Beta
##  Min.   :1.301             Min.   :1.301            Min.   :1.301           
##  1st Qu.:4.035             1st Qu.:3.119            1st Qu.:3.546           
##  Median :4.343             Median :3.514            Median :3.931           
##  Mean   :4.307             Mean   :3.485            Mean   :3.913           
##  3rd Qu.:4.627             3rd Qu.:3.898            3rd Qu.:4.324           
##  Max.   :5.666             Max.   :5.326            Max.   :5.414           
##  NA's   :22                NA's   :25               NA's   :24              
##  Day29pseudoneutid50_Delta Day29pseudoneutid50_BA.4.BA.5
##  Min.   :1.301             Min.   :1.301                
##  1st Qu.:3.679             1st Qu.:2.889                
##  Median :3.998             Median :3.267                
##  Mean   :3.988             Mean   :3.229                
##  3rd Qu.:4.320             3rd Qu.:3.644                
##  Max.   :5.402             Max.   :4.907                
##  NA's   :24                NA's   :24                   
##  Day29pseudoneutid50_D614G Day91pseudoneutid50_BA.1 Day91pseudoneutid50_Beta
##  Min.   :1.301             Min.   :1.301            Min.   :1.301           
##  1st Qu.:3.968             1st Qu.:2.948            1st Qu.:3.349           
##  Median :4.278             Median :3.400            Median :3.739           
##  Mean   :4.256             Mean   :3.340            Mean   :3.731           
##  3rd Qu.:4.574             3rd Qu.:3.779            3rd Qu.:4.179           
##  Max.   :5.605             Max.   :5.190            Max.   :5.420           
##  NA's   :24                NA's   :121              NA's   :121             
##  Day91pseudoneutid50_Delta Day91pseudoneutid50_BA.4.BA.5
##  Min.   :1.301             Min.   :1.301                
##  1st Qu.:3.482             1st Qu.:2.719                
##  Median :3.821             Median :3.187                
##  Mean   :3.815             Mean   :3.126                
##  3rd Qu.:4.180             3rd Qu.:3.615                
##  Max.   :5.438             Max.   :4.975                
##  NA's   :121               NA's   :121                  
##  Day91pseudoneutid50_D614G Day181pseudoneutid50_BA.1 Day181pseudoneutid50_Beta
##  Min.   :1.301             Min.   :1.301             Min.   :1.301            
##  1st Qu.:3.772             1st Qu.:2.855             1st Qu.:3.155            
##  Median :4.122             Median :3.297             Median :3.614            
##  Mean   :4.107             Mean   :3.237             Mean   :3.561            
##  3rd Qu.:4.459             3rd Qu.:3.749             3rd Qu.:4.021            
##  Max.   :5.624             Max.   :5.228             Max.   :5.298            
##  NA's   :121               NA's   :157               NA's   :157              
##  Day181pseudoneutid50_Delta Day181pseudoneutid50_BA.4.BA.5
##  Min.   :1.301              Min.   :1.301                 
##  1st Qu.:3.289              1st Qu.:2.612                 
##  Median :3.657              Median :3.154                 
##  Mean   :3.623              Mean   :3.065                 
##  3rd Qu.:3.991              3rd Qu.:3.599                 
##  Max.   :5.118              Max.   :4.913                 
##  NA's   :157                NA's   :157                   
##  Day181pseudoneutid50_D614G Day85pseudoneutid50_BA.1 Day85pseudoneutid50_Beta
##  Min.   :1.301              Min.   :1.301            Min.   :1.301           
##  1st Qu.:3.656              1st Qu.:3.289            1st Qu.:3.646           
##  Median :3.993              Median :3.574            Median :4.078           
##  Mean   :3.966              Mean   :3.614            Mean   :4.012           
##  3rd Qu.:4.346              3rd Qu.:4.009            3rd Qu.:4.365           
##  Max.   :5.601              Max.   :4.837            Max.   :5.144           
##  NA's   :157                NA's   :1177             NA's   :1177            
##  Day85pseudoneutid50_Delta Day85pseudoneutid50_BA.4.BA.5
##  Min.   :1.301             Min.   :1.301                
##  1st Qu.:3.710             1st Qu.:2.982                
##  Median :3.942             Median :3.215                
##  Mean   :3.994             Mean   :3.307                
##  3rd Qu.:4.365             3rd Qu.:3.709                
##  Max.   :5.082             Max.   :4.623                
##  NA's   :1177              NA's   :1177                 
##  Day85pseudoneutid50_D614G Day147pseudoneutid50_BA.1 Day147pseudoneutid50_Beta
##  Min.   :1.301             Min.   :1.301             Min.   :1.301            
##  1st Qu.:3.892             1st Qu.:3.030             1st Qu.:3.255            
##  Median :4.189             Median :3.384             Median :3.721            
##  Mean   :4.213             Mean   :3.418             Mean   :3.704            
##  3rd Qu.:4.557             3rd Qu.:3.886             3rd Qu.:4.092            
##  Max.   :5.179             Max.   :4.796             Max.   :4.740            
##  NA's   :1177              NA's   :1176              NA's   :1176             
##  Day147pseudoneutid50_Delta Day147pseudoneutid50_BA.4.BA.5
##  Min.   :1.301              Min.   :1.301                 
##  1st Qu.:3.369              1st Qu.:2.616                 
##  Median :3.694              Median :3.070                 
##  Mean   :3.700              Mean   :3.078                 
##  3rd Qu.:4.130              3rd Qu.:3.696                 
##  Max.   :4.803              Max.   :4.481                 
##  NA's   :1176               NA's   :1176                  
##  Day147pseudoneutid50_D614G symptm_infect1   symptm_infect1_date
##  Min.   :1.301              Min.   :0.0000   Length:1262        
##  1st Qu.:3.630              1st Qu.:0.0000   Class :character   
##  Median :3.984              Median :0.0000   Mode  :character   
##  Mean   :3.999              Mean   :0.2979                      
##  3rd Qu.:4.373              3rd Qu.:1.0000                      
##  Max.   :4.963              Max.   :1.0000                      
##  NA's   :1176                                                   
##   N_status_1.0    N_status_15.2 N_status_181.14 N_status_271.14 
##  Min.   :0.0000   Min.   :0     Min.   :0.000   Min.   :0.0000  
##  1st Qu.:0.0000   1st Qu.:0     1st Qu.:0.000   1st Qu.:0.0000  
##  Median :0.0000   Median :0     Median :1.000   Median :1.0000  
##  Mean   :0.3315   Mean   :0     Mean   :0.552   Mean   :0.5795  
##  3rd Qu.:1.0000   3rd Qu.:0     3rd Qu.:1.000   3rd Qu.:1.0000  
##  Max.   :1.0000   Max.   :0     Max.   :1.000   Max.   :1.0000  
##  NA's   :1        NA's   :22    NA's   :157     NA's   :375     
##  N_status_29.2    N_status_91.7    Actual_visit_date_1.0 Actual_visit_date_15.2
##  Min.   :0.0000   Min.   :0.0000   Length:1262           Length:1262           
##  1st Qu.:0.0000   1st Qu.:0.0000   Class :character      Class :character      
##  Median :0.0000   Median :0.0000   Mode  :character      Mode  :character      
##  Mean   :0.3586   Mean   :0.4663                                               
##  3rd Qu.:1.0000   3rd Qu.:1.0000                                               
##  Max.   :1.0000   Max.   :1.0000                                               
##  NA's   :24       NA's   :121                                                  
##  Actual_visit_date_181.14 Actual_visit_date_271.14 Actual_visit_date_29.2
##  Length:1262              Length:1262              Length:1262           
##  Class :character         Class :character         Class :character      
##  Mode  :character         Mode  :character         Mode  :character      
##                                                                          
##                                                                          
##                                                                          
##                                                                          
##  Actual_visit_date_91.7 first_Npos_date    Target_study_day_numeric
##  Length:1262            Length:1262        Min.   :  1.00          
##  Class :character       Class :character   1st Qu.:  1.00          
##  Mode  :character       Mode  :character   Median :  1.00          
##                                            Mean   : 71.81          
##                                            3rd Qu.:181.00          
##                                            Max.   :271.00          
##                                            NA's   :497             
##  NumberdaysD15toD29 NumberdaysD15toD91 NumberdaysD15toD181 last_contact_date 
##  Min.   : 6.00      Min.   : 54.00     Min.   : 98.0       Length:1262       
##  1st Qu.:13.00      1st Qu.: 70.00     1st Qu.:154.0       Class :character  
##  Median :14.00      Median : 75.00     Median :159.0       Mode  :character  
##  Mean   :14.18      Mean   : 74.64     Mean   :158.9                         
##  3rd Qu.:15.00      3rd Qu.: 77.00     3rd Qu.:167.0                         
##  Max.   :34.00      Max.   :102.00     Max.   :191.0                         
##  NA's   :38         NA's   :134        NA's   :173                           
##   Perprotocol     symptm_infect1_date_imp oos_boost_date_imp
##  Min.   :0.0000   Length:1262             Length:1262       
##  1st Qu.:1.0000   Class :character        Class :character  
##  Median :1.0000   Mode  :character        Mode  :character  
##  Mean   :0.9794                                             
##  3rd Qu.:1.0000                                             
##  Max.   :1.0000                                             
##                                                             
##  early_term_date_imp EarlyendpointD15  Immunemarkerset 
##  Length:1262         Min.   :0.00000   Min.   :0.0000  
##  Class :character    1st Qu.:0.00000   1st Qu.:1.0000  
##  Mode  :character    Median :0.00000   Median :1.0000  
##                      Mean   :0.01936   Mean   :0.9604  
##                      3rd Qu.:0.00000   3rd Qu.:1.0000  
##                      Max.   :1.00000   Max.   :1.0000  
##                      NA's   :22                        
##  ImmunemarkersetD92toD181    ph1.D15         ph1.D92          ph1.D29      
##  Min.   :0.0000           Min.   :0.000   Min.   :0.0000   Min.   :0.0000  
##  1st Qu.:1.0000           1st Qu.:1.000   1st Qu.:0.0000   1st Qu.:0.0000  
##  Median :1.0000           Median :1.000   Median :1.0000   Median :0.0000  
##  Mean   :0.7971           Mean   :0.893   Mean   :0.7393   Mean   :0.1086  
##  3rd Qu.:1.0000           3rd Qu.:1.000   3rd Qu.:1.0000   3rd Qu.:0.0000  
##  Max.   :1.0000           Max.   :1.000   Max.   :1.0000   Max.   :1.0000  
##                                                                            
##  CNSR1_D22toD91     CNSR1_D92toD181    CNSR1_D22toD181    CNSR1_D36toD181   
##  Length:1262        Length:1262        Length:1262        Length:1262       
##  Class :character   Class :character   Class :character   Class :character  
##  Mode  :character   Mode  :character   Mode  :character   Mode  :character  
##                                                                             
##                                                                             
##                                                                             
##                                                                             
##  CNSR1_D22toend        CNSR2              CNSR3              CNSR4          
##  Length:1262        Length:1262        Length:1262        Length:1262       
##  Class :character   Class :character   Class :character   Class :character  
##  Mode  :character   Mode  :character   Mode  :character   Mode  :character  
##                                                                             
##                                                                             
##                                                                             
##                                                                             
##     CNSR5           CNSR_D22toD91      CNSR_D92toD181     CNSR_D22toD181    
##  Length:1262        Length:1262        Length:1262        Length:1262       
##  Class :character   Class :character   Class :character   Class :character  
##  Mode  :character   Mode  :character   Mode  :character   Mode  :character  
##                                                                             
##                                                                             
##                                                                             
##                                                                             
##  CNSR_D36toD181     CNSR_D22toend      COVIDtimeD22toD91 COVIDIndD22toD91
##  Length:1262        Length:1262        Min.   :-14.00    Min.   :0.0000  
##  Class :character   Class :character   1st Qu.: 91.00    1st Qu.:0.0000  
##  Mode  :character   Mode  :character   Median : 91.00    Median :0.0000  
##                                        Mean   : 79.48    Mean   :0.1332  
##                                        3rd Qu.: 91.00    3rd Qu.:0.0000  
##                                        Max.   : 91.00    Max.   :1.0000  
##                                        NA's   :22        NA's   :46      
##  COVIDtimeD92toD181 COVIDIndD92toD181 COVIDtimeD22toD181 COVIDIndD22toD181
##  Min.   :-14.0      Min.   :0.00000   Min.   :-14.0      Min.   :0.0000   
##  1st Qu.: 94.0      1st Qu.:0.00000   1st Qu.: 94.0      1st Qu.:0.0000   
##  Median :171.0      Median :0.00000   Median :171.0      Median :0.0000   
##  Mean   :140.2      Mean   :0.07102   Mean   :140.2      Mean   :0.1941   
##  3rd Qu.:188.0      3rd Qu.:0.00000   3rd Qu.:188.0      3rd Qu.:0.0000   
##  Max.   :188.0      Max.   :1.00000   Max.   :188.0      Max.   :1.0000   
##  NA's   :22         NA's   :220       NA's   :22         NA's   :46       
##  COVIDtimeD36toD181 COVIDIndD36toD181 COVIDIndD22toend AsympInfectIndD15to29
##  Min.   :-27.0      Min.   :0.000     Min.   :0.0000   Min.   :0.00000      
##  1st Qu.: 82.0      1st Qu.:0.000     1st Qu.:0.0000   1st Qu.:0.00000      
##  Median :156.0      Median :0.000     Median :0.0000   Median :0.00000      
##  Mean   :132.3      Mean   :0.179     Mean   :0.2163   Mean   :0.01109      
##  3rd Qu.:188.0      3rd Qu.:0.000     3rd Qu.:0.0000   3rd Qu.:0.00000      
##  Max.   :188.0      Max.   :1.000     Max.   :1.0000   Max.   :1.00000      
##  NA's   :24         NA's   :72        NA's   :46                            
##  AsympInfectIndD30to91 AsympInfectIndD15to91 AsympInfectIndD92to181
##  Min.   :0.00000       Min.   :0.00000       Min.   :0.0000        
##  1st Qu.:0.00000       1st Qu.:0.00000       1st Qu.:0.0000        
##  Median :0.00000       Median :0.00000       Median :0.0000        
##  Mean   :0.01664       Mean   :0.02773       Mean   :0.0206        
##  3rd Qu.:0.00000       3rd Qu.:0.00000       3rd Qu.:0.0000        
##  Max.   :1.00000       Max.   :1.00000       Max.   :1.0000        
##                                                                    
##  AsympInfectIndD182to271 AsympInfectIndD15to181 AsympInfectIndD15to271
##  Min.   :0.00000         Min.   :0.00000        Min.   :0.00000       
##  1st Qu.:0.00000         1st Qu.:0.00000        1st Qu.:0.00000       
##  Median :0.00000         Median :0.00000        Median :0.00000       
##  Mean   :0.01347         Mean   :0.04834        Mean   :0.06181       
##  3rd Qu.:0.00000         3rd Qu.:0.00000        3rd Qu.:0.00000       
##  Max.   :1.00000         Max.   :1.00000        Max.   :1.00000       
## 
sort(names(dat_mapped))
##   [1] "Actual_visit_date_1.0"                        
##   [2] "Actual_visit_date_15.2"                       
##   [3] "Actual_visit_date_181.14"                     
##   [4] "Actual_visit_date_271.14"                     
##   [5] "Actual_visit_date_29.2"                       
##   [6] "Actual_visit_date_91.7"                       
##   [7] "Age"                                          
##   [8] "Age65C"                                       
##   [9] "arm"                                          
##  [10] "Asian"                                        
##  [11] "ASSAY"                                        
##  [12] "ASSCOMP_SWAB1"                                
##  [13] "ASSCOMP_SWAB2"                                
##  [14] "ASSQC_SWAB1"                                  
##  [15] "ASSQC_SWAB2"                                  
##  [16] "ASSSTAT_SWAB1"                                
##  [17] "ASSSTAT_SWAB2"                                
##  [18] "AsympInfectIndD15to181"                       
##  [19] "AsympInfectIndD15to271"                       
##  [20] "AsympInfectIndD15to29"                        
##  [21] "AsympInfectIndD15to91"                        
##  [22] "AsympInfectIndD182to271"                      
##  [23] "AsympInfectIndD30to91"                        
##  [24] "AsympInfectIndD92to181"                       
##  [25] "BACRDPCT_SWAB1"                               
##  [26] "BACRDPCT_SWAB2"                               
##  [27] "Black"                                        
##  [28] "Bpseudoneutid50_BA.1"                         
##  [29] "Bpseudoneutid50_BA.4.BA.5"                    
##  [30] "Bpseudoneutid50_Beta"                         
##  [31] "Bpseudoneutid50_D614G"                        
##  [32] "Bpseudoneutid50_Delta"                        
##  [33] "Bpseudoneutid50Duke_BA.2.12.1"                
##  [34] "City"                                         
##  [35] "CNSR_D22toD181"                               
##  [36] "CNSR_D22toD91"                                
##  [37] "CNSR_D22toend"                                
##  [38] "CNSR_D36toD181"                               
##  [39] "CNSR_D92toD181"                               
##  [40] "CNSR1_D22toD181"                              
##  [41] "CNSR1_D22toD91"                               
##  [42] "CNSR1_D22toend"                               
##  [43] "CNSR1_D36toD181"                              
##  [44] "CNSR1_D92toD181"                              
##  [45] "CNSR2"                                        
##  [46] "CNSR3"                                        
##  [47] "CNSR4"                                        
##  [48] "CNSR5"                                        
##  [49] "COVIDIndD22toD181"                            
##  [50] "COVIDIndD22toD91"                             
##  [51] "COVIDIndD22toend"                             
##  [52] "COVIDIndD36toD181"                            
##  [53] "COVIDIndD92toD181"                            
##  [54] "COVIDtimeD22toD181"                           
##  [55] "COVIDtimeD22toD91"                            
##  [56] "COVIDtimeD36toD181"                           
##  [57] "COVIDtimeD92toD181"                           
##  [58] "COVRDPCT_SWAB1"                               
##  [59] "COVRDPCT_SWAB2"                               
##  [60] "CTSTAT_SWAB1"                                 
##  [61] "CTSTAT_SWAB2"                                 
##  [62] "CTVALUE_SWAB1"                                
##  [63] "CTVALUE_SWAB2"                                
##  [64] "D1_D15_flag"                                  
##  [65] "D1_D29_flag"                                  
##  [66] "DATE_COLLECT_SWAB1"                           
##  [67] "DATE_COLLECT_SWAB2"                           
##  [68] "Day147pseudoneutid50_BA.1"                    
##  [69] "Day147pseudoneutid50_BA.4.BA.5"               
##  [70] "Day147pseudoneutid50_Beta"                    
##  [71] "Day147pseudoneutid50_D614G"                   
##  [72] "Day147pseudoneutid50_Delta"                   
##  [73] "Day15pseudoneutid50_BA.1"                     
##  [74] "Day15pseudoneutid50_BA.4.BA.5"                
##  [75] "Day15pseudoneutid50_Beta"                     
##  [76] "Day15pseudoneutid50_D614G"                    
##  [77] "Day15pseudoneutid50_Delta"                    
##  [78] "Day15pseudoneutid50Duke_BA.2.12.1"            
##  [79] "Day181pseudoneutid50_BA.1"                    
##  [80] "Day181pseudoneutid50_BA.4.BA.5"               
##  [81] "Day181pseudoneutid50_Beta"                    
##  [82] "Day181pseudoneutid50_D614G"                   
##  [83] "Day181pseudoneutid50_Delta"                   
##  [84] "Day29pseudoneutid50_BA.1"                     
##  [85] "Day29pseudoneutid50_BA.4.BA.5"                
##  [86] "Day29pseudoneutid50_Beta"                     
##  [87] "Day29pseudoneutid50_D614G"                    
##  [88] "Day29pseudoneutid50_Delta"                    
##  [89] "Day85pseudoneutid50_BA.1"                     
##  [90] "Day85pseudoneutid50_BA.4.BA.5"                
##  [91] "Day85pseudoneutid50_Beta"                     
##  [92] "Day85pseudoneutid50_D614G"                    
##  [93] "Day85pseudoneutid50_Delta"                    
##  [94] "Day91pseudoneutid50_BA.1"                     
##  [95] "Day91pseudoneutid50_BA.4.BA.5"                
##  [96] "Day91pseudoneutid50_Beta"                     
##  [97] "Day91pseudoneutid50_D614G"                    
##  [98] "Day91pseudoneutid50_Delta"                    
##  [99] "early_term"                                   
## [100] "early_term_date"                              
## [101] "early_term_date_imp"                          
## [102] "EarlyendpointD15"                             
## [103] "eligibility_deviation"                        
## [104] "EthnicityHispanic"                            
## [105] "EthnicityNotreported"                         
## [106] "first_Npos_date"                              
## [107] "HSTRDPCT_SWAB1"                               
## [108] "HSTRDPCT_SWAB2"                               
## [109] "Immunemarkerset"                              
## [110] "ImmunemarkersetD92toD181"                     
## [111] "infect_date1"                                 
## [112] "infect_date2"                                 
## [113] "last_contact_date"                            
## [114] "Multiracial"                                  
## [115] "N_status_1.0"                                 
## [116] "N_status_15.2"                                
## [117] "N_status_181.14"                              
## [118] "N_status_271.14"                              
## [119] "N_status_29.2"                                
## [120] "N_status_91.7"                                
## [121] "naive"                                        
## [122] "NAntibody"                                    
## [123] "NatAmer"                                      
## [124] "NumberdaysD15toD181"                          
## [125] "NumberdaysD15toD29"                           
## [126] "NumberdaysD15toD91"                           
## [127] "oos_boost"                                    
## [128] "oos_boost_date"                               
## [129] "oos_boost_date_imp"                           
## [130] "PacIsl"                                       
## [131] "PANGOLIN_SWAB1"                               
## [132] "PANGOLIN_SWAB2"                               
## [133] "PANGOVER_SWAB1"                               
## [134] "PANGOVER_SWAB2"                               
## [135] "Perprotocol"                                  
## [136] "ph1.D15"                                      
## [137] "ph1.D29"                                      
## [138] "ph1.D92"                                      
## [139] "pre_study_booster_date"                       
## [140] "pre_study_booster_until_studydose1_day"       
## [141] "pre_study_booster_until_studydose1_day_median"
## [142] "pre_study_booster_until_studydose1_ind"       
## [143] "pre_study_infect_date"                        
## [144] "primary_booster_type"                         
## [145] "primary_vax1_date"                            
## [146] "primary_vax2_date"                            
## [147] "race"                                         
## [148] "RESULT"                                       
## [149] "RESULT_limit"                                 
## [150] "SCORCALL_SWAB1"                               
## [151] "SCORCALL_SWAB2"                               
## [152] "SCORVER_SWAB1"                                
## [153] "SCORVER_SWAB2"                                
## [154] "Sex"                                          
## [155] "SPKAADEL_SWAB1"                               
## [156] "SPKAADEL_SWAB2"                               
## [157] "SPKAAINS_SWAB1"                               
## [158] "SPKAAINS_SWAB2"                               
## [159] "SPKAASUB_SWAB1"                               
## [160] "SPKAASUB_SWAB2"                               
## [161] "stage"                                        
## [162] "State"                                        
## [163] "stratalab"                                    
## [164] "studydose1date"                               
## [165] "studydose2date"                               
## [166] "Subjectid"                                    
## [167] "symptm_infect1"                               
## [168] "symptm_infect1_date"                          
## [169] "symptm_infect1_date_imp"                      
## [170] "symptomatic_infect1"                          
## [171] "symptomatic_infect2"                          
## [172] "Target_study_day_numeric"                     
## [173] "TOTREADS_SWAB1"                               
## [174] "TOTREADS_SWAB2"                               
## [175] "treatment_actual"                             
## [176] "treatment_assigned"                           
## [177] "TrtA"                                         
## [178] "TrtB"                                         
## [179] "TrtC"                                         
## [180] "TrtmRNA"                                      
## [181] "TrtonedosemRNA"                               
## [182] "TrtSanofi"                                    
## [183] "TRUNCLIN_SWAB1"                               
## [184] "TRUNCLIN_SWAB2"                               
## [185] "TRUNCVER_SWAB1"                               
## [186] "TRUNCVER_SWAB2"                               
## [187] "UNITS"                                        
## [188] "Unknown"                                      
## [189] "White"
table(dat_mapped$treatment_actual, dat_mapped$stage)
##                                                 
##                                                    1   2   3   4
##   1 Dose Beta + Omicron (Moderna)                113   0   0   0
##   1 Dose Delta + Omicron (Moderna)               101   0   0   0
##   1 Dose Omicron (Moderna)                        99   0   0   0
##   1 Dose Omicron + Prototype (Moderna)            99   0   0   0
##   1 Dose Prototype (Moderna)                      99   0   0   0
##   2 Dose Beta + Omicron (Moderna)                 86   0   0   0
##   Beta (Pfizer 1)                                  0  51   0   0
##   Beta (Sanofi)                                    0   0  51   0
##   Beta + Omicron (Pfizer 1)                        0  52   0   0
##   Beta + Prototype (Sanofi)                        0   0  52   0
##   Beta + Wildtype/Prototype (Pfizer 1)             0  52   0   0
##   Omicron (Pfizer 1)                               0  54   0   0
##   Omicron + Wildtype/Prototype (Pfizer 1)          0  53   0   0
##   Omicron BA.1 + Wildtype/Prototype (Pfizer 2)     0   0   0 101
##   Omicron BA.4/5 + Wildtype/Prototype (Pfizer 2)   0   0   0 100
##   Prototype (Sanofi)                               0   0  49   0
##   Wildtype/Prototype (Pfizer 1)                    0  50   0   0
with(subset(dat, ph1.D15==1 & COVIDIndD22toD181), mytable(treatment_actual, COVIDlineageObserved))
##                                                 COVIDlineageObserved
## treatment_actual                                 FALSE TRUE
##   1 Dose Beta + Omicron (Moderna)                    9   28
##   1 Dose Delta + Omicron (Moderna)                   5   23
##   1 Dose Omicron (Moderna)                           7   18
##   1 Dose Omicron + Prototype (Moderna)               8   18
##   1 Dose Prototype (Moderna)                         7   20
##   Beta (Pfizer 1)                                    4    5
##   Beta + Omicron (Pfizer 1)                          3    4
##   Beta + Wildtype/Prototype (Pfizer 1)               2    7
##   Omicron (Pfizer 1)                                 5    3
##   Omicron + Wildtype/Prototype (Pfizer 1)            0    6
##   Omicron BA.1 + Wildtype/Prototype (Pfizer 2)       3    5
##   Omicron BA.4/5 + Wildtype/Prototype (Pfizer 2)     2    5
##   Wildtype/Prototype (Pfizer 1)                      4   12
table(dat_mapped$Immunemarkerset, dat_mapped$Perprotocol, useNA='ifany')
##    
##        0    1
##   0   26   24
##   1    0 1212
table(dat_mapped$Immunemarkerset, dat_mapped$eligibility_deviation, useNA='ifany')
##    
##             Y
##   0   47    3
##   1 1212    0